Phil Thompson <[EMAIL PROTECTED]> wrote:

> I'm not sure if anything can be done to detect and/or prevent the problem.
> It would be easy enough to contrive the same problem in C++, so I don't
> really see it as a PyQt problem. I'm open to suggestions.

What about adding adding a flag (static variable in the derived destructor)
which records if we are already destroying the object? So that, if the
derived destructor gets re-invoked as part of a reference cycle, it just
silently exits without doing anything. I think you have a similar variable,
which records if the C++-side of the object is destroyed or not... maybe you
could set that at the very start of the derived destructor.

>> The second problem is a memory leak:
>
> I'll think about this tomorrow - my head hurts at the moment.

Sure :)
-- 
Giovanni Bajo

_______________________________________________
PyKDE mailing list    PyKDE@mats.imk.fraunhofer.de
http://mats.imk.fraunhofer.de/mailman/listinfo/pykde

Reply via email to