Commits

Anonymous committed 7346b2d

fixed BinnedBitSet memory leak

  • Participants
  • Parent commits 38dc8eb

Comments (0)

Files changed (2)

lib/bx/bitset.pyx

         if size > MAX_INT:
             raise ValueError( "%d is larger than the maximum BinnedBitSet size of %d." % ( size, MAX_INT ) )
         self.bb = binBitsAlloc( size, granularity )
-    def __dealloc( self ):
+    def __dealloc__( self ):
         binBitsFree( self.bb );
     def __getitem__( self, index ):
         bb_check_index( self, index )
             bitFree( &(bb->bins[i]) );
         }
     }
+    freeMem( bb->bins );
     freeMem( bb );
 }