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

[Issue 244][zstdProvider] Fix zstd memory leak #245

Merged
merged 2 commits into from
May 15, 2020

Conversation

rueian
Copy link
Contributor

@rueian rueian commented May 13, 2020

Fixes #244

Motivation

The current implementation of zstdProvider.Decompress doesn't close the zstd decoder and will lead to memory leak, mentioned in the issue.

Modifications

Use the decoder.DecodeAll to implement zstdProvider.Decompress and reuse the decoder.
And also upgrade klauspost/compress to v1.10.5.

Copy link
Member

@wolfstudy wolfstudy left a comment

Choose a reason for hiding this comment

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

Cool LGTM +1

@wolfstudy wolfstudy merged commit 2dad2b3 into apache:master May 15, 2020
@wolfstudy wolfstudy added this to the 0.1.1 milestone Jun 9, 2020
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.

Memory Leak zstdProvider.Decompress
3 participants