refcount/memleak debugging?

Will Ware wware at world.std.com
Thu Sep 14 02:26:06 CEST 2000


I'm working on a C extension using SWIG 1.3a4, dynamically linking to
Python 1.5.2 on a Linux box. I've tried to be pretty careful about
putting in enough Py_DECREFs, but I must have done something wrong
because memory appears to be leaking. My test that memory is leaking
is to watch the memory usage increasing (according to "top") on a
script that should very quickly settle into using a constant amount
of memory.  Is there some better way to detect memory leaks? Are there
any guidelines published anywhere for identifying them? I'm starting
to putter with Py_DECREF and the global reference count, maybe that
will tell me something. Any hints appreciated.
-- 
# - - - - - - - - - - - - - - - - - - - - - - - -
# Resistance is futile. Capacitance is efficacious.
# Will Ware	email:    wware @ world.std.com



More information about the Python-list mailing list