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 memory leak in compactCells #685

Merged
merged 4 commits into from
Sep 12, 2022

Conversation

isaacbrodsky
Copy link
Collaborator

This branch was previously thought unreachable, but evidently is. It resulted in a memory leak which allowed us to detect it. I added a test based on a specific bad input and assert that it returns failure, plus rely on Valgrind to detect if a leak happens; it may be possible to minify the test case even further.

We should convert these "unreachable" branches to assertions, at least for debug builds so we can be sure to find other such cases in e.g. fuzzing.

@coveralls
Copy link

coveralls commented Sep 11, 2022

Coverage Status

Coverage increased (+0.002%) to 99.037% when pulling e22eaf3 on isaacbrodsky:fix-compactcells-leak into f581626 on uber:master.

src/apps/testapps/testCompactCells.c Outdated Show resolved Hide resolved
Co-authored-by: David Ellis <isv.damocles@gmail.com>
@isaacbrodsky isaacbrodsky merged commit cbd294a into uber:master Sep 12, 2022
@isaacbrodsky isaacbrodsky deleted the fix-compactcells-leak branch September 12, 2022 23:55
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.

4 participants