Skip to content

Fix XZBlock padding calculation when its stream's starting position % 4 != 0#878

Merged
adamhathcock merged 4 commits intoadamhathcock:masterfrom
Morilli:fix-xzblock-padding
Dec 20, 2024
Merged

Fix XZBlock padding calculation when its stream's starting position % 4 != 0#878
adamhathcock merged 4 commits intoadamhathcock:masterfrom
Morilli:fix-xzblock-padding

Conversation

@Morilli
Copy link
Contributor

@Morilli Morilli commented Oct 29, 2024

I've also removed the unused _bytesRead field that seems to have last been touched in #300.

@Morilli
Copy link
Contributor Author

Morilli commented Oct 29, 2024

Hm, test failures seem to occur because XZBlock is instantiated with a (RewindableStream) stream that throws an exception when accessing its Position... not sure how valid that even is, considering reading the block would eventually fail anyways because SkipPadding already accesses the stream's position before this change.

@adamhathcock
Copy link
Owner

Thanks!

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.

Padding calculation wrong when starting position % 4 != 0

2 participants