-
Notifications
You must be signed in to change notification settings - Fork 5.4k
Fix TarReader: implement full GNU sparse format 1.0 (PAX) reading with DataStream expansion #125283
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
Copilot
wants to merge
29
commits into
main
Choose a base branch
from
copilot/fix-gnu-sparse-format-handling
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
29 commits
Select commit
Hold shift + click to select a range
e609249
Initial plan
Copilot 543c8f2
Fix TarReader to handle GNU sparse format 1.0 (PAX) - resolve GNU.spa…
Copilot 351d885
Fix copy constructor to propagate _gnuSparseRealSize; improve test as…
Copilot cd7c720
Merge branch 'main' into copilot/fix-gnu-sparse-format-handling
lewing 5db74bb
Implement full GNU sparse format 1.0 PAX DataStream expansion via Gnu…
Copilot 1015043
Fix GnuSparseStream: add MaxSparseSegments DoS limit, precompute pack…
Copilot c34240f
Address reviewer feedback: simplify error strings, minor=0 check, typ…
Copilot 583239c
Address remaining reviewer feedback: group sparse attrs, IndexOf-base…
Copilot 498e3e9
Move sparse tests to TarReader.SparseFile.Tests.cs, add corrupted for…
Copilot fc05df3
Address review: merge sync/async ParseSparseMap, 1024-byte buffer, Ut…
Copilot 24f0fb3
Fix TarReader: implement full GNU sparse format 1.0 (PAX) reading wit…
Copilot 91213c7
Merge remote-tracking branch 'upstream/main' into copilot/fix-gnu-spa…
rzikm d656d45
Move async sparse tests to TarReader.SparseFile.Tests.cs
rzikm 24e7e62
Fix buffer overflow in ParseSparseMap for long malformed lines
rzikm f78a16e
Add test: copy sparse entry to new archive preserves expanded content
rzikm 87212d5
Refactor: separate _gnuSparseDataStream from _dataStream, simplify Re…
rzikm 35a72b9
Fix ReadFromPackedData positioning and add copy round-trip test
rzikm e1fed30
Merge remote-tracking branch 'origin/main' into copilot/fix-gnu-spars…
Copilot 48132ab
Merge latest main, add archive size assert in test, fix FindSegmentFr…
Copilot e4a2b76
Defer sparse map parsing to first Read for non-seekable stream support
rzikm 451f9e0
Add non-seekable source tests for sparse entry copy round-trip
rzikm df76255
Verify archive size when copying
rzikm 26cb2ca
Consolidate sparse layout tests into single parameterized test
rzikm feed417
Deduplicate some tests
rzikm 482b139
Deduplicate remaining sparse tests
rzikm 3e41073
Address code review: remove unused _dataStart, add overflow check, fi…
rzikm 6cdfd74
Use ArrayPool for ParseSparseMap buffer
rzikm 313d905
Validate sparse map segment ordering and bounds
rzikm 2d25c96
Use MemberData for corrupted sparse map tests, exercise all cases syn…
rzikm File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
468 changes: 468 additions & 0 deletions
468
src/libraries/System.Formats.Tar/src/System/Formats/Tar/GnuSparseStream.cs
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This replaced an async block with a sync one in an async method