Skip to content

Commit

Permalink
fix: provide bigger line buffer to reflog iterator so long lines can …
Browse files Browse the repository at this point in the history
…be read.

Otherwise, the revlog iteration may stop unexpectedly on long lines.
  • Loading branch information
Byron committed Dec 21, 2024
1 parent c6a0569 commit 2a9274c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion gix-ref/src/store/file/log/iter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ impl Platform<'_, '_> {
/// Return a forward iterator over all log-lines, most recent to oldest.
pub fn rev(&mut self) -> std::io::Result<Option<log::iter::Reverse<'_, std::fs::File>>> {
self.buf.clear();
self.buf.resize(512, 0);
self.buf.resize(1024 * 4, 0);
self.store
.reflog_iter_rev(self.name, &mut self.buf)
.map_err(must_be_io_err)
Expand Down

0 comments on commit 2a9274c

Please sign in to comment.