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.
Create valid xar files by creating file nodes, eg Contents -> Resources -> foo.txt
Before we were just creating all top-level items with paths that had multiple path components, instead of any parent entries, but doing this was wrong.
I also noticed and fixed some incorrect logic determining file equality in creation by the file hash. Now it makes sure the file/symlink contents are equal or they're both directory entires.
This does not break older clients. The applying logic was fortunately written in a way where no changes there are required.
We thus do not need to bump the major version, but we are bumping the minor version of the format here.
I will cherry-pick this change to 1.x once approved / merged.
Fixes #1899
Checklist:
Type of change
Testing
I tested and verified my change by using one or multiple of these methods:
All unit tests pass.
Tested creating and applying new binary delta files between two different versions of an app.
Tested applying a newly generated binary delta file using an older binary delta version works.
Tested both of these combinations on Big Sur and Monterey beta machines.
macOS version tested:
11.5 (20G71)
12.0 Beta (21A5284e)