Opened 5 years ago

Last modified 5 years ago

#24660 closed defect

Memory leak in SubgraphSearch — at Version 1

Reported by: Konrad127123 Owned by:
Priority: major Milestone: sage-8.2
Component: graph theory Keywords: memory leak, SubgraphSearch
Cc: Merged in:
Authors: Konrad K. Dabrowski Reviewers:
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Status badges

Description (last modified by Konrad127123)

In SubgraphSearch? in generic_graph_pyx.pyx

cinit contains the line: self.tmp_array = <int *> sig_malloc( * sizeof(int))

but dealloc is missing the line: sig_free(self.tmp_array)

This leads to a memory leak, which can be demonstrated with:

for i in xrange(1,1000000):
    if i%10000==0:

Without the missing line, the memory usage keeps increasing (about 32 bytes per iteration). With the line added, the memory usage is constant.

Change History (1)

comment:1 Changed 5 years ago by Konrad127123

  • Authors set to Konrad K. Dabrowski
  • Component changed from PLEASE CHANGE to memleak
  • Description modified (diff)
  • Keywords memory leak SubgraphSearch added
  • Type changed from PLEASE CHANGE to defect
Note: See TracTickets for help on using tickets.