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

fixed many undetected memory leaks in trurl #233

Merged
merged 1 commit into from
Aug 25, 2023

Conversation

jacobmealey
Copy link
Contributor

This PR adds a heap of fixes to undetected memory errors in trurl. These memory errors were discovered by building trurl against a debug version of libcurl and running make test-memory which discovered 55 memory errors on my machine. This PR doesn't fix all of them, but it does fix most of them.

When running on my machine there are 2 tests which fail, both of which are a --verify test with early exits where the error message includes some string that was dynamically allocated. These two are tricky to fix with out reworking all of the error handling system. A simple fix is propagating the struct option to every function that could error and have the error function clean up the option struct after printing, this seems like a gross solution though and I thought that it should probably be thought over more and done in a separate PR.

@bagder bagder merged commit dfd7db2 into curl:master Aug 25, 2023
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