[prev in list] [next in list] [prev in thread] [next in thread] 

List:       pykde
Subject:    Re: [PyKDE] Seg Faults on Fedora Core 2 with kde-redhat RPMS
From:       Jim Bublitz <jbublitz () nwinternet ! com>
Date:       2004-08-27 17:16:36
Message-ID: 200408271016.36129.jbublitz () nwinternet ! com
[Download RAW message or body]

On Friday 27 August 2004 08:55, Jonathan Gardner wrote:
> I'm getting Seg Faults (core dumps, crashes) in general with the RPMs from
> kde-redhat.

> datepicker.py runs, but when it is closed, it segfaults. (See attached).

It's likely that KApplication.quit() isn't going to work reliably. I don't 
recall all of the details, but it's related to the way KDE uses or implements 
KMainWindow I believe. The solution is use a KMainWindow as the app's main 
widget, and call KMainWindow.close() when quitting (which also allows you to 
use queryClose() and queryExit() ). In datepicker.py, make KDatePicker a 
child of a KMainWindow instance.

I haven't looked at this in a while, but I don't think it's possible to get 
KApplication.quit(), KMainWindow.close() and KMainWindow.queryClose() to work 
all at the same time, so I made the choice to favor KMainWindow.  If I recall 
correctly, there's some contention between KApplication.quit(), 
QApplication.quit() and the KMainWindow methods.

There should probably be something in the docs about this.

I'm not sure if calling KDatePicker.close() instead of KApplication.quit() 
would work, but you could try that too.

> database.py runs, but when it is cleaning up, a segfaul is caused. I think
> I traced it down to when it deletes the QLibrary, but I am not certain.

> All the examples I tested in both PyQt and PyKDE seem to work flawlessly,
> however.


Jim

_______________________________________________
PyKDE mailing list    PyKDE@mats.imk.fraunhofer.de
http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic