[Bug 561303] Re: PyQt4 applications crash at exit

Sybren Stüvel sybren at stuvel.eu
Sat May 22 11:57:44 UTC 2010


Personally I would classify this as a workaround. IMO not following a
good-practice should not result in a segfault.

My usage of QApplication is rather unique, in that I create and destroy
multiple QApplication instances sequentially, in the same process. You
don't need to bother with setting QtGui.qApp if your process stops when
the QApplication instance stops.

Maybe setting QtGui.qApp = None after each QApplication has shut down is
enough to solve the segfault. However, I chose to be thorough and set it
always. It's only two lines of extra code.

QtCore.qApp is indeed a typo, the code is correct in using QtGui.qApp.
Thanks for pointing that out.

-- 
PyQt4 applications crash at exit
https://bugs.launchpad.net/bugs/561303
You received this bug notification because you are a member of Kubuntu
Bugs, which is subscribed to python-qt4 in ubuntu.




More information about the kubuntu-bugs mailing list