Memory leak in python-2.2.3 on solaris?

Martin v. Löwis martin at v.loewis.de
Tue Nov 4 16:39:41 EST 2003


edahl at mindspring.com (Erwin Dahl) writes:

> - is this really a leak in python (or one of its libraries)?

Without seeing the source code, nobody can tell.

> - if gettotalrefcount() stays the same it must be a C level leak,
> correct?

If it is a leak: yes.

> - if so what is the best way to figure it out? 

Add a breakpoint on malloc, and find out what its callers are.

> I'm on solaris 2.8 and python is built with gcc 3.2.2. The program
> doesn't use many libraries the ones that I haven't been able to pull
> when debuging are socket and select so I suspect them.

You might want to incorporate them statically into Python, by
modifying Modules/Setup.

Regards,
Martin





More information about the Python-list mailing list