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 a possible memory leak in Data.readChunk #331

Merged

Conversation

kbinani
Copy link
Contributor

@kbinani kbinani commented Aug 26, 2024

There is a memory leak in Data.readChunk when fread fails to read data.
This PR fixes it by deallocating memory before throwing an exception.

I didn't create an issue for this, as the problem is obvious, but please let me know if an issue is needed.

@weichsel
Copy link
Owner

weichsel commented Sep 2, 2024

Thanks - Good catch!

@weichsel weichsel merged commit fac78df into weichsel:development Sep 2, 2024
8 of 18 checks passed
@kbinani kbinani deleted the fix-memory-leadk-at-data-readchunk branch September 2, 2024 19:46
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.

2 participants