Skip to content
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

Fix stream decompression corner case failure #89

Merged
merged 1 commit into from
Jan 15, 2024

Conversation

brantburnett
Copy link
Owner

Motivation

In cases where the stream decompression block read hits with a start point within the middle of a tag but then the literal is longer than the entire block available we are incorrectly handling the _lookbackPosition when we return.

Modifications

Refactor the handling to be a bit less confusing and correct the result. Add a test for the failure case.

Fixes #88

Motivation
----------
In cases where the stream decompression block read hits with a start
point within the middle of a tag but then the literal is longer than the
entire block available we are incorrectly handling the _lookbackPosition
when we return.

Modifications
-------------
Refactor the handling to be a bit less confusing and correct the
result. Add a test for the failure case.

Fixes #88
@brantburnett brantburnett merged commit 11be394 into main Jan 15, 2024
30 checks passed
@brantburnett brantburnett deleted the decompression-fail branch January 15, 2024 03:41
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.

Snappy decompression will fail on certain sequence of bytes.
2 participants