Py_Finalize

Pablo Yabo pyabo at novamens.com
Fri Feb 20 10:37:17 EST 2004


I use Py_DECREF when the module is no longer needed, but when I call
PyImport_Import the reference count of the module is 2, so after
decrementing the reference count it doesn't unload.

----- Original Message ----- 
From: "Paul Miller" <paul at fxtech.com>
To: "Pablo Yabo" <pyabo at novamens.com>; "Gerhard Häring" <gh at ghaering.de>;
<python-list at python.org>
Sent: Friday, February 20, 2004 12:22 PM
Subject: Re: Py_Finalize


>
> >I do that and the memory always increase.
> >If I comment the module loads the memory stay stable, but if I load the
> >modules the memory increases and never return to the previous level.
>
> How are you running your scripts? If using PyImport, try Py_DECREF the
> returned module objects before you call Py_Finalize.
>
>
>






More information about the Python-list mailing list