[Kde-pim] KMail crashes when message box is shown on startup

Thomas McGuire thomas.mcguire at gmx.net
Sat Jun 9 22:00:29 BST 2007


Hello,

KMail currently crashes when any messagebox is shown at startup, before the 
kernel is fully initialized.

One example is the messagebox from transportmanager, which asks to migrate all 
passwords to KWallet.
This messagebox is shown when the kernel is initializing, which is before the 
main event loop is entered.

The problem is that KMessageBox calls the main event loop. 
There we get an event which tells us to create the application instance, 
therefore KMailApplication::newInstance() is called. This function creates a 
mainwindow and does other initializations, which won't work (crash) because 
the kernel is not yet fully initialized.

Attached is hacky patch which solves the problem. However, I guess this is not 
the proper method and breaks some things, probably some KUniqueApplication 
logic.

I guess in Qt3 the messageboxes didn't call the event loop, which is why it 
doesn't crash there.

Any ideas how to solve this properly?

Regards,
Thomas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch
Type: text/x-diff
Size: 1324 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20070609/942759d9/attachment.diff>
-------------- next part --------------
_______________________________________________
kde-pim mailing list
kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
kde-pim home page at http://pim.kde.org/


More information about the kde-pim mailing list