Skip to content
Snippets Groups Projects

Fix memory leak in the CHOLMOD wrapper code

Merged Oliver Sander requested to merge fix-memory-leak-in-cholmod-solver into master
All threads resolved!

When calling CHOLMOD to compute the Cholesky factor of a matrix, it was not tested whether such a factor already existed. As a consequence, if the solver was called twice in a row, the old factor would be lost to a memory leak.

Fix this by explicitly deallocating the old Cholesky factor before asking CHOLMOD for a new one.

I am amazed that this has gone unnoticed for so long. It's a massive leak.

The fix should go into 2.10 as well.

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Oliver Sander added 1 commit

    added 1 commit

    • e4ffbb1f - Fix memory leak in the CHOLMOD wrapper code

    Compare with previous version

  • Oliver Sander resolved all threads

    resolved all threads

  • merged

  • Oliver Sander mentioned in commit 2eff058f

    mentioned in commit 2eff058f

  • Nice catch. Thanks

  • Please register or sign in to reply
    Loading