Skip to content

Commit

Permalink
Update logging when flushing write buffer. It is misleading or strang…
Browse files Browse the repository at this point in the history
…e to report flushing 0 bytes left.

PiperOrigin-RevId: 698524519
  • Loading branch information
jwcullen committed Nov 25, 2024
1 parent 803b39f commit 71d6380
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion iamf/common/write_bit_buffer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,9 @@ absl::Status WriteBitBuffer::FlushAndWriteToFile(
RETURN_IF_NOT_OK(WriteBufferToFile(bit_buffer_, *output_file));
}

LOG_EVERY_POW_2(INFO) << "Flushing " << bit_offset_ / 8 << " bytes";
if (bit_offset_ > 0) {
LOG_EVERY_POW_2(INFO) << "Flushing " << bit_offset_ / 8 << " bytes";
}
Reset();
return absl::OkStatus();
}
Expand Down

0 comments on commit 71d6380

Please sign in to comment.