[PyKDE] PyQt crash

Phil Thompson phil at riverbankcomputing.co.uk
Thu Nov 30 21:36:25 GMT 2006


On Thursday 30 November 2006 4:46 pm, Giovanni Bajo wrote:
> Hello,
>
> the following code snippet causes a segfault:
> >>> from qt import QApplication
> >>> app = QApplication(["-v"]*10)
> >>> del app
> >>> app = QApplication([])
>
> I'm using Qt 3.3.6, PyQt 3.16, SIP 4.4.3, under Windows.

It will be fixed in tonight's snapshot. A workaround is to pass a dummy 
argument in the second ctor call.

Note that PyQt4 handles QApplication differently and delays calling the dtor 
until the interpreter exits. So, in the above case, you will have two 
QApplication instances existing at the same time.

Phil




More information about the PyQt mailing list