Skip to content

[Backport 1.2-maint] ChunkerFixed: do not take a short read for EOF (1.4-maint) - #10567

Closed
github-actions[bot] wants to merge 2 commits into
1.2-maintfrom
backport-10563-to-1.2-maint
Closed

github-actions[bot] wants to merge 2 commits into
1.2-maintfrom
backport-10563-to-1.2-maint

Conversation

@github-actions

Copy link
Copy Markdown

Description

Backport of #10563 to 1.2-maint.

ThomasWaldmann and others added 2 commits October 29, 2026 20:51
blockify() stopped reading the whole input as soon as a read returned less
than the requested block size. A short read is not EOF though, e.g. when
reading from a pipe: "borg create --read-special" with the fixed chunker
archived only the first 64 KiB of a FIFO's content (seen on macOS) and
silently dropped the rest.

Now keep reading until the block is complete or a read returns nothing.
Filling the block also keeps the chunk boundaries at fixed offsets.

master is not affected any more, see #10166.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
(cherry picked from commit d244470)
Same behaviour and same read calls, just one loop instead of a first
read followed by a loop for the rest of the block.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
(cherry picked from commit 6498b37)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant