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

zstd: Add DecodeAllCapLimit #649

Merged
merged 3 commits into from
Jul 29, 2022
Merged

zstd: Add DecodeAllCapLimit #649

merged 3 commits into from
Jul 29, 2022

Conversation

klauspost
Copy link
Owner

WithDecodeAllCapLimit will limit DecodeAll to decoding cap(dst)-len(dst) bytes, or any size set in WithDecoderMaxMemory.

This can be used to limit decoding to a specific maximum output size.

Disabled by default.

Fixes #647

WithDecodeAllCapLimit will limit DecodeAll to decoding cap(dst)-len(dst) bytes, or any size set in WithDecoderMaxMemory.

This can be used to limit decoding to a specific maximum output size.

Disabled by default.

Fixes #647
Copy link
Contributor

@dsnet dsnet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I only did a high-level look through and it generally looks sensible. I'll report if there are any bugs with it.

@klauspost
Copy link
Owner Author

@dsnet I will merge it, so it is easier for you to test. I will however not release, since I am mostly AFK for the next few weeks, just FYI.

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.

proposal: zstd: add DecodedSize function
2 participants