Version: (using KDE Devel) Installed from: Compiled sources Compiler: gcc 3.4.1 OS: Linux Kopete crashes when KDE gets quit. I have Kopete running with a Jabber account and use the IRC plugin as well. Kopete usually resides in the Tray and works normally. But when leaving KDE it causes segmentation faults as you can see in the report: Using host libthread_db library "/lib/libthread_db.so.1". [Thread debugging using libthread_db enabled] [New Thread 16384 (LWP 815)] [New Thread 32769 (LWP 827)] [Thread debugging using libthread_db enabled] [New Thread 16384 (LWP 815)] [New Thread 32769 (LWP 827)] [Thread debugging using libthread_db enabled] [New Thread 16384 (LWP 815)] [New Thread 32769 (LWP 827)] [New Thread 16386 (LWP 828)] [New Thread 65539 (LWP 833)] [New Thread 81924 (LWP 834)] [KCrash handler] #6 0xb78892a6 in KPluginInfo::icon () from /usr/local/lib/libkutils.so.1 #7 0xb7f48f0d in Kopete::Plugin::pluginIcon () from /usr/local/lib/libkopete.so.1 #8 0xb7f36004 in Kopete::OnlineStatus::Private::protocolIcon () from /usr/local/lib/libkopete.so.1 #9 0xb7f3746c in Kopete::OnlineStatus::mimeSourceFor () from /usr/local/lib/libkopete.so.1 #10 0xb5da45a8 in JabberBaseContact::reevaluateStatus () from /usr/local/lib/kde3/kopete_jabber.so #11 0xb5da2490 in JabberResourcePool::notifyRelevantContacts () from /usr/local/lib/kde3/kopete_jabber.so #12 0xb5da2a53 in JabberResourcePool::addResource () from /usr/local/lib/kde3/kopete_jabber.so #13 0xb5d9ce5a in JabberAccount::setPresence () from /usr/local/lib/kde3/kopete_jabber.so #14 0xb5d9cfe4 in JabberAccount::disconnect () from /usr/local/lib/kde3/kopete_jabber.so #15 0xb5d9c05a in JabberAccount::disconnect () from /usr/local/lib/kde3/kopete_jabber.so #16 0xb5d9c090 in JabberAccount::~JabberAccount () from /usr/local/lib/kde3/kopete_jabber.so #17 0xb7f38e6e in Kopete::Protocol::~Protocol () from /usr/local/lib/libkopete.so.1 #18 0xb5d9898a in JabberProtocol::~JabberProtocol () from /usr/local/lib/kde3/kopete_jabber.so #19 0xb7f43e8b in Kopete::PluginManager::~PluginManager () from /usr/local/lib/libkopete.so.1 #20 0xb7f48cdf in KStaticDeleter<Kopete::PluginManager>::destructObject () from /usr/local/lib/libkopete.so.1 #21 0xb710da1f in KGlobal::deleteStaticDeleters () from /usr/local/lib/libkdecore.so.4 #22 0xb707d02f in KApplication::~KApplication () from /usr/local/lib/libkdecore.so.4 #23 0xb711bfa4 in KUniqueApplication::~KUniqueApplication () from /usr/local/lib/libkdecore.so.4 #24 0x08067d35 in KopeteApplication::~KopeteApplication () #25 0x080678b9 in main ()
are you using kdelibs from HEAD with kopete from HEAD? or are you using kdelibs from KDE 3.3.x?
> are you using kdelibs from HEAD with kopete from HEAD? yes (I usually compile in a fresh directory, no old libs mess). > are you using kdelibs from KDE 3.3.x? no Though, this was seen with KDE 3.3.0 and 3.3.1 (RELEASE TAG) as well.
I just got this crash when exiting Kopete: #3 <signal handler called> #4 0x400baff1 in QMapPrivate<QString, Kopete::ContactProperty>::end() const ( this=0x10) at qmap.h:380 #5 0x400ba977 in QMap<QString, Kopete::ContactProperty>::end() const ( this=0x82ae880) at qmap.h:663 #6 0x400ba1d5 in QMap<QString, Kopete::ContactProperty>::contains(QString const&) const (this=0x82ae880, k=@0x827d0f0) at qmap.h:703 #7 0x400b7534 in Kopete::Contact::hasProperty(QString const&) const ( this=0x8295118, key=@0x827d0f0) at kopetecontact.cpp:624 #8 0x400b7562 in Kopete::Contact::property(QString const&) const ( this=0x8295118, key=@0x827d0f0) at kopetecontact.cpp:629 #9 0x42692305 in ChatView::addNickLinks(QString const&) const ( this=0x83495b0, html=@0xbfffef20) at chatview.cpp:1366 #10 0x42691a4c in ChatView::addChatMessage(Kopete::Message&) (this=0x83495b0, message=@0xbfffefa0) at chatview.cpp:1322 #11 0x42690bd3 in ChatView::sendInternalMessage(QString const&, Kopete::Message::MessageFormat) (this=0x83495b0, msg=@0xbffff000, format=PlainText) at chatview.cpp:1116 #12 0x4268fd62 in ChatView::slotContactRemoved(Kopete::Contact const*, QString const&, Kopete::Message::MessageFormat, bool) (this=0x83495b0, contact=0x82963b8, reason=@0x8482bc0, format=PlainText, suppressNotification=false) at chatview.cpp:912 #13 0x42697bb5 in ChatView::qt_invoke(int, QUObject*) (this=0x83495b0, _id=104, _o=0xbffff100) at chatview.moc:531 #14 0x4131b8ac in QObject::activate_signal(QConnectionList*, QUObject*) () from /opt/qt/lib/libqt-mt.so.3 #15 0x400c851e in Kopete::MessageManager::contactRemoved(Kopete::Contact const*, QString const&, Kopete::Message::MessageFormat, bool) (this=0x8334b00, t0=0x82963b8, t1=@0x80e5a38, t2=PlainText, t3=false) at kopetemessagemanager.moc:328 #16 0x400c7ca0 in Kopete::MessageManager::slotContactDestroyed(Kopete::Contact*) (this=0x8334b00, contact=0x82963b8) at kopetemessagemanager.cpp:447 #17 0x400c8d32 in Kopete::MessageManager::qt_invoke(int, QUObject*) ( this=0x8334b00, _id=20, _o=0xbffff290) at kopetemessagemanager.moc:393 #18 0x42815250 in JabberMessageManager::qt_invoke(int, QUObject*) ( this=0x8334b00, _id=20, _o=0xbffff290) at jabbermessagemanager.moc:101 #19 0x4131b826 in QObject::activate_signal(QConnectionList*, QUObject*) () from /opt/qt/lib/libqt-mt.so.3 #20 0x400b9064 in Kopete::Contact::contactDestroyed(Kopete::Contact*) ( this=0x82963b8, t0=0x82963b8) at kopetecontact.moc:192 #21 0x400b4bb6 in ~Contact (this=0x82963b8) at kopetecontact.cpp:114 #22 0x4280c4c9 in ~JabberBaseContact (this=0x82963b8) at jabbercontact.cpp:48 #23 0x4280c075 in ~JabberContact (this=0x82963b8) at jabbercontact.moc:524 #24 0x400e7e77 in ~Account (this=0x8290a88) at kopeteaccount.cpp:89 #25 0x40107314 in ~PasswordedAccount (this=0x8290a88) at kopetepasswordedaccount.cpp:40 #26 0x427f6863 in ~JabberAccount (this=0x8290a88) at jabberaccount.cpp:102 #27 0x4131914c in QObject::event(QEvent*) () from /opt/qt/lib/libqt-mt.so.3 #28 0x412bfecf in QApplication::internalNotify(QObject*, QEvent*) () from /opt/qt/lib/libqt-mt.so.3 #29 0x412bf4db in QApplication::notify(QObject*, QEvent*) () from /opt/qt/lib/libqt-mt.so.3 #30 0x40e5db74 in KApplication::notify(QObject*, QEvent*) () from /opt/kde/lib/libkdecore.so.4
I can confirm _a_ crash on logout, not sure if it's this one or not
I currently see this: Trying to quit Kopete with accounts connected -> the readyForUnload signal never gets emitted (not sure by which plugin yet), and the shutdown timer comes in and brute-force unloads the plugins. There appear to be destruction-order problems causing various crashes with brute-force unloading. I've seen, at least, Jabber and IRC cause problems. So, our last-resort fallback is getting called, and is causing crashes. I've never felt happy about the plugin manager's unload timer... maybe this is a sign that it should go away? Removing the timeout, kopete hangs on shutdown waiting for plugins to say they're ready to unload (never seems to happen here). Sending a dcop kopete MainApplication quit causes Kopete to segfault. Ideally, I'd like to make sure plugins do emit readyToUnload (or whatever it's called), and remove the plugin manager's timeout. But the real world isn't ideal, so the timeout should probably stay. A KUniqueApp crashing is better than it hanging with no visible UI ;(
*** Bug 91993 has been marked as a duplicate of this bug. ***
*** Bug 97969 has been marked as a duplicate of this bug. ***
I've fixed today several crashes when closing kopete I hope it's fixed.
I still get crashes on exit with 3.4 RC1.
I experience the issue too (kde 3.4 rc1), using jabber and icq. I've filed a bugreport http://bugs.kde.org/show_bug.cgi?id=100528 , but seems that my report should be marked as a duplicate for this bug.
Not fixed.
*** Bug 100528 has been marked as a duplicate of this bug. ***
Backtrace from HEAD: #0 0x0000002a96ddd7e0 in KPluginInfo::icon (this=0x0) at /space/kde/head/src/kdelibs/kutils/kplugininfo.cpp:221 #1 0x0000002a95879b95 in Kopete::Plugin::pluginIcon (this=0xd20ac0) at /space/kde/head/src/kdenetwork/kopete/libkopete/kopeteplugin.cpp:60 #2 0x0000002a95865572 in Kopete::OnlineStatus::Private::protocolIcon (this=0xa62d20) at /space/kde/head/src/kdenetwork/kopete/libkopete/kopeteonlinestatus.cpp:52 #3 0x0000002a95864ff0 in Kopete::OnlineStatus::mimeSourceFor (this=0x7fbfffe830, account=0x9cecf0, size=16) at /space/kde/head/src/kdenetwork/kopete/libkopete/kopeteonlinestatus.cpp:246 #4 0x0000002a9c1634ed in JabberBaseContact::reevaluateStatus (this=0x9bf380) at /space/kde/head/src/kdenetwork/kopete/protocols/jabber/jabberbasecontact.cpp:204 #5 0x0000002a9c160821 in JabberResourcePool::notifyRelevantContacts (this=0x9a8ae0, jid=@0x7fbfffeb70) at /space/kde/head/src/kdenetwork/kopete/protocols/jabber/jabberresourcepool.cpp:65 #6 0x0000002a9c160b6f in JabberResourcePool::addResource (this=0x9a8ae0, jid=@0x7fbfffeb70, resource=@0x7fbfffeb00) at /space/kde/head/src/kdenetwork/kopete/protocols/jabber/jabberresourcepool.cpp:102 #7 0x0000002a9c15c467 in JabberAccount::setPresence (this=0x9cecf0, status=@0x7fbfffec50) at /space/kde/head/src/kdenetwork/kopete/protocols/jabber/jabberaccount.cpp:1130 #8 0x0000002a9c15b1e2 in JabberAccount::disconnect (this=0x9cecf0, reason=Manual) at /space/kde/head/src/kdenetwork/kopete/protocols/jabber/jabberaccount.cpp:755 #9 0x0000002a9c1582c4 in ~JabberAccount (this=0x9cecf0) at /space/kde/head/src/kdenetwork/kopete/protocols/jabber/jabberaccount.cpp:101 #10 0x0000002a95869c0c in ~Protocol (this=0xd20ac0) at /space/kde/head/src/kdenetwork/kopete/libkopete/kopeteprotocol.cpp:73 #11 0x0000002a9c155fc3 in ~JabberProtocol (this=0xd20ac0) at /space/kde/head/src/kdenetwork/kopete/protocols/jabber/jabberprotocol.cpp:115 #12 0x0000002a9587568d in ~PluginManager (this=0x7c12f0) at /space/kde/head/src/kdenetwork/kopete/libkopete/kopetepluginmanager.cpp:113 #13 0x0000002a958796ce in KStaticDeleter<Kopete::PluginManager>::destructObject (this=0x2a95a29760) at kstaticdeleter.h:126 #14 0x0000002a97d745a5 in KGlobal::deleteStaticDeleters () at /space/kde/head/src/kdelibs/kdecore/kglobal.cpp:189 #15 0x0000002a97ce54d4 in ~KApplication (this=0x7fbfffef40) at /space/kde/head/src/kdelibs/kdecore/kapplication.cpp:1626 #16 0x0000002a97d83e29 in ~KUniqueApplication (this=0x7fbfffef40) at /space/kde/head/src/kdelibs/kdecore/kuniqueapplication.cpp:350 #17 0x0000000000438320 in ~KopeteApplication (this=0x7fbfffef40) at /space/kde/head/src/kdenetwork/kopete/kopete/kopeteapplication.cpp:120 #18 0x0000000000437c04 in main (argc=7, argv=0x7fbffff298) at /space/kde/head/src/kdenetwork/kopete/kopete/main.cpp:99
*** Bug 100886 has been marked as a duplicate of this bug. ***
Created attachment 10016 [details] Suggested patch CAUSE Richard's analysis above was correct, that plugins were not being unloaded. This was because KApplication::quitKopete() was never called in KopeteWindow::closeEvent() - the logic there was broken and I can't understand why it was left like that. REMEDY This patch goes quite a long way: * Remove ref/deref complexity from the PluginManager and give responsibility for closing down the app to KopeteApplication::quitKopete() which calls KApplication::quit(). * Remove the WDestructiveClose on KopeteWindow - it makes it easier to use QCloseEvent::accept() to hide the window, and the instance is deleted in any case by ~KopeteApplication(). * Simplify KopeteWindow::closeEvent() so that it accepts the QCloseEvent in either case, but detects when the app should also be quit, quits it using KopeteWindow::slotQuit(), and therefore KopeteApplication::quitKopete(). * Remove redundant call to KMainWindow::queryExit() which is { return true; } * Remove a couple of other bits of cruft.
Please test. Many others have worked in this area before and there seem to be a number of pitfalls - quitting the app too early (relative to the loaded plugins - the cause of the above crash, cf #75805), quitting the app too late or not at all (a kopete instance with no gui, cf #71657), doing the wrong thing when the system tray icon is not used, not working with session management. As it's my first touch of the ball I've definitely made a glaring mistake somewhere so help me find it!
sorry the patch doesn't help. it still crashes on logout.
[tobias@Wohnung ~]$ kopete [tobias@Wohnung ~]$ QGDict::hashKeyString: Invalid null key QGDict::hashKeyString: Invalid null key QMetaObject::findSignal:ClientStream: Conflict with Stream::readyRead() QMetaObject::findSignal:ClientStream: Conflict with Stream::readyRead() [tobias@Wohnung ~]$ QGDict::hashKeyString: Invalid null key KCrash: Application 'kopete' crashing...
Please tell me which protocols you are using and which you were online with at the time of the crash. Then try the following: Start kopete go online switch to a text console or start another X session in the other console/session: ps -ef | grep kopete gdb -p <PID of kopete> 'c'ontinue kopete when gdb has started switch back to X log out of KDE switch to the other console get a backtrace from gdb with 'bt'
protocols are icq,irc and jabber. attachment of backtrace will be uploaded now, but we have no debug symbols so i don't think it will help you much.
Created attachment 10020 [details] backtrace of kopete crash, but without debugging symbols
Tobias: The backtrace is very useful. Please backup your .kde/share/config/kopeterc, remove your IRC account and see if the crash goes away without it.
ok will do that after lunch :) in 30 minutes or so.
For future reference: please paste the backtraces, instead of attaching them. We have a tool that searches backtraces for similarity, but it doesn't work in attachments. Program received signal SIGSEGV, Segmentation fault. [Switching to Thread -1246279968 (LWP 26053)] 0xb7479bff in KXMLGUI::ActionList::unplug () from /opt/kde/lib/libkdeui.so.4 #0 0xb7479bff in KXMLGUI::ActionList::unplug () from /opt/kde/lib/libkdeui.so.4 #1 0xb751f0b5 in KXMLGUI::ContainerNode::unplugClient () from /opt/kde/lib/libkdeui.so.4 #2 0xb751f3fb in KXMLGUI::ContainerNode::unplugActions () from /opt/kde/lib/libkdeui.so.4 #3 0xb751f47c in KXMLGUI::ContainerNode::destruct () from /opt/kde/lib/libkdeui.so.4 #4 0xb751f684 in KXMLGUI::ContainerNode::destructChildren () from /opt/kde/lib/libkdeui.so.4 #5 0xb751f470 in KXMLGUI::ContainerNode::destruct () from /opt/kde/lib/libkdeui.so.4 #6 0xb751f684 in KXMLGUI::ContainerNode::destructChildren () from /opt/kde/lib/libkdeui.so.4 #7 0xb751f470 in KXMLGUI::ContainerNode::destruct () from /opt/kde/lib/libkdeui.so.4 #8 0xb751f946 in KXMLGUIFactory::removeClient () from /opt/kde/lib/libkdeui.so.4 #9 0xb751fd18 in KXMLGUIFactory::removeClient () from /opt/kde/lib/libkdeui.so.4 #10 0xb428d356 in KopeteChatWindow::setActiveView () from /opt/kde/lib/kde3/kopete_chatwindow.so #11 0xb4297d95 in KopeteChatWindow::qt_invoke () from /opt/kde/lib/kde3/kopete_chatwindow.so #12 0xb6b4f7e4 in QObject::activate_signal () from /opt/qt/lib/libqt-mt.so.3 #13 0xb6ec15fd in QTabWidget::currentChanged () from /opt/qt/lib/libqt-mt.so.3 #14 0xb6c83dd3 in QTabWidget::showTab () from /opt/qt/lib/libqt-mt.so.3 #15 0xb6ec1714 in QTabWidget::qt_invoke () from /opt/qt/lib/libqt-mt.so.3 #16 0xb74b23a5 in KTabWidget::qt_invoke () from /opt/kde/lib/libkdeui.so.4 #17 0xb6b4f7e4 in QObject::activate_signal () from /opt/qt/lib/libqt-mt.so.3 #18 0xb6b4fe0b in QObject::activate_signal () from /opt/qt/lib/libqt-mt.so.3 #19 0xb6ec0eb0 in QTabBar::selected () from /opt/qt/lib/libqt-mt.so.3 #20 0xb6c81ae4 in QTabBar::setCurrentTab () from /opt/qt/lib/libqt-mt.so.3 #21 0xb6c83e23 in QTabWidget::setCurrentPage () from /opt/qt/lib/libqt-mt.so.3 #22 0xb428d701 in KopeteChatWindow::detachChatView () from /opt/kde/lib/kde3/kopete_chatwindow.so #23 0xb428d7cc in ChatView::closeView () from /opt/kde/lib/kde3/kopete_chatwindow.so #24 0xb7f9a79d in KopeteViewManager::slotChatSessionDestroyed () from /opt/kde/lib/libkopete.so.1 #25 0xb7f9b98b in KopeteViewManager::qt_invoke () from /opt/kde/lib/libkopete.so.1 #26 0xb6b4f7e4 in QObject::activate_signal () from /opt/qt/lib/libqt-mt.so.3 #27 0xb7f173cd in Kopete::ChatSession::closing () from /opt/kde/lib/libkopete.so.1 #28 0xb7f42326 in Kopete::ChatSession::~ChatSession () from /opt/kde/lib/libkopete.so.1 #29 0xb6b4e449 in QObject::~QObject () from /opt/qt/lib/libqt-mt.so.3 #30 0xb7f2f88b in Kopete::Account::~Account () from /opt/kde/lib/libkopete.so.1 #31 0xb7f2fa47 in Kopete::PasswordedAccount::~PasswordedAccount () from /opt/kde/lib/libkopete.so.1 #32 0xb5390438 in IRCAccount::~IRCAccount () from /opt/kde/lib/kde3/kopete_irc.so #33 0xb6b4ccec in QObject::event () from /opt/qt/lib/libqt-mt.so.3 #34 0xb6aebd8f in QApplication::internalNotify () from /opt/qt/lib/libqt-mt.so.3 ---Type <return> to continue, or q <return> to quit--- #35 0xb6aebf82 in QApplication::notify () from /opt/qt/lib/libqt-mt.so.3 #36 0xb71f52c5 in KApplication::notify () from /opt/kde/lib/libkdecore.so.4 #37 0xb6aecda0 in QApplication::sendPostedEvents () from /opt/qt/lib/libqt-mt.so.3 #38 0xb6b024f6 in QEventLoop::enterLoop () from /opt/qt/lib/libqt-mt.so.3 #39 0xb6b023b6 in QEventLoop::exec () from /opt/qt/lib/libqt-mt.so.3 #40 0xb6aeaeff in QApplication::exec () from /opt/qt/lib/libqt-mt.so.3 #41 0x080786f0 in ?? () #42 0xbffff490 in ?? () #43 0xbffff470 in ?? () #44 0xbffff470 in ?? () #45 0x00000000 in ?? () #46 0x080bd0be in _IO_stdin_used () #47 0x00000001 in ?? () #48 0x080be4d0 in _IO_stdin_used () #49 0x080bccf5 in _IO_stdin_used () #50 0x080bcd0a in _IO_stdin_used () #51 0x080bccdc in _IO_stdin_used () #52 0xb72a4420 in spinlock () from /opt/kde/lib/libkdecore.so.4 #53 0x00000000 in ?? () #54 0x00000220 in ?? () #55 0xb72a4820 in av_ () from /opt/kde/lib/libkdecore.so.4 #56 0xbffff498 in ?? () #57 0xb7249623 in malloc () from /opt/kde/lib/libkdecore.so.4 #58 0xb62d319d in __libc_start_main () from /lib/tls/libc.so.6 #59 0x08069cc1 in ?? ()
ok sorry didn't know that, thanks for correcting this. you are right removed irc and now no crash happens anymore, add irc again and the crash comes back.
There's at least one problem case with my patch, when quitting a group chat a warning dialog appears, causing this: Crash when quitting KDE session, Kopete IRC + Jabber, chatwindow open with tabs for #kopete and #kde-devel - quitting group chat warning dialog appeared. Session management called commitData on our mainwindows, sending a QCloseEvent to each one, and closing the group chat window showed a dialog, which put us back in the event loop, where there was a deleteLater waiting to delete the account? #0 0x0000000000935217 in ?? () #1 0x0000002a9772aa65 in KXMLGUI::ActionList::unplug (this=0xa24668, container=0xaeb8f0) at /space/kde/head/src/kdelibs/kdeui/kxmlguifactory_p.cpp:44 #2 0x0000002a9772bda4 in KXMLGUI::ContainerNode::unplugClient ( this=0xaea450, client=0xa24660) at /space/kde/head/src/kdelibs/kdeui/kxmlguifactory_p.cpp:426 #3 0x0000002a9772bc71 in KXMLGUI::ContainerNode::unplugActions ( this=0xaea450, state=@0xa5f910) at /space/kde/head/src/kdelibs/kdeui/kxmlguifactory_p.cpp:406 #4 0x0000002a9772b7ff in KXMLGUI::ContainerNode::destruct ( this=0xaea450, element=<incomplete type>, state=@0xa5f910) at /space/kde/head/src/kdelibs/kdeui/kxmlguifactory_p.cpp:313 #5 0x0000002a9772ba35 in KXMLGUI::ContainerNode::destructChildren ( this=0xa29510, element=@0x7fbfffcbe0, state=@0xa5f910) at /space/kde/head/src/kdelibs/kdeui/kxmlguifactory_p.cpp:358 #6 0x0000002a9772b7f2 in KXMLGUI::ContainerNode::destruct ( this=0xa29510, element=<incomplete type>, state=@0xa5f910) at /space/kde/head/src/kdelibs/kdeui/kxmlguifactory_p.cpp:311 #7 0x0000002a9772ba35 in KXMLGUI::ContainerNode::destructChildren ( this=0xa5e350, element=@0x7fbfffccf0, state=@0xa5f910) at /space/kde/head/src/kdelibs/kdeui/kxmlguifactory_p.cpp:358 #8 0x0000002a9772b7f2 in KXMLGUI::ContainerNode::destruct ( this=0xa5e350, element=<incomplete type>, state=@0xa5f910) at /space/kde/head/src/kdelibs/kdeui/kxmlguifactory_p.cpp:311 #9 0x0000002a97727d8d in KXMLGUIFactory::removeClient ( this=0xa5cab0, client=0xa293e0) at /space/kde/head/src/kdelibs/kdeui/kxmlguifactory.cpp:364 #10 0x0000002a97727bb8 in KXMLGUIFactory::removeClient ( this=0xa5cab0, client=0x92f260) at /space/kde/head/src/kdelibs/kdeui/kxmlguifactory.cpp:339 #11 0x0000002a9c84900c in KopeteChatWindow::setActiveView ( this=0xa3ce30, widget=0xcc4020) at /space/kde/head/src/kdenetwork/kopete/kopete/chatwindow/kopetechatwindow.cpp:789 #12 0x0000002a9c84a68d in KopeteChatWindow::qt_invoke (this=0xa3ce30, _id=77, _o=0x7fbfffcf00) at kopetechatwindow.moc:215 #13 0x0000002a989eb909 in QObject::activate_signal () from /usr/lib/qt3/lib64/libqt-mt.so.3 #14 0x0000002a98cdd432 in QTabWidget::currentChanged () from /usr/lib/qt3/lib64/libqt-mt.so.3 #15 0x0000002a98af75e3 in QTabWidget::showTab () from /usr/lib/qt3/lib64/libqt-mt.so.3 #16 0x0000002a98cdd33d in QTabWidget::qt_invoke () from /usr/lib/qt3/lib64/libqt-mt.so.3 #17 0x0000002a97791c12 in KTabWidget::qt_invoke (this=0xdadda0, _id=49, _o=0x7fbfffd040) at ktabwidget.moc:388 #18 0x0000002a989eb909 in QObject::activate_signal () from /usr/lib/qt3/lib64/libqt-mt.so.3 #19 0x0000002a989ebe73 in QObject::activate_signal () from /usr/lib/qt3/lib64/libqt-mt.so.3 #20 0x0000002a98cdcd65 in QTabBar::selected () from /usr/lib/qt3/lib64/libqt-mt.so.3 #21 0x0000002a98af404c in QTabBar::setCurrentTab () from /usr/lib/qt3/lib64/libqt-mt.so.3 #22 0x0000002a98af76e9 in QTabWidget::setCurrentPage () #23 0x0000002a9c848b2a in KopeteChatWindow::detachChatView ( this=0xa3ce30, view=0x92a0d0) at /space/kde/head/src/kdenetwork/kopete/kopete/chatwindow/kopetechatwindow.cpp:689 #24 0x0000002a9c83fc7a in ChatView::closeView (this=0x92a0d0, force=true) at /space/kde/head/src/kdenetwork/kopete/kopete/chatwindow/chatview.cpp:372 #25 0x0000002a958d8186 in KopeteViewManager::slotChatSessionDestroyed (this=0x888980, manager=0x92f210) at /space/kde/head/src/kdenetwork/kopete/libkopete/private/kopeteviewmanager.cpp:319 #26 0x0000002a958d83e0 in KopeteViewManager::qt_invoke ( this=0x888980, _id=6, _o=0x7fbfffd340) at kopeteviewmanager.moc:120 #27 0x0000002a989eb909 in QObject::activate_signal () from /usr/lib/qt3/lib64/libqt-mt.so.3 #28 0x0000002a958801c5 in Kopete::ChatSession::closing ( this=0x92f210, t0=0x92f210) at kopetemessagemanager.moc:277 #29 0x0000002a9587eeb7 in ~ChatSession (this=0x92f210) at /space/kde/head/src/kdenetwork/kopete/libkopete/kopetemessagemanager.cpp:95 #30 0x0000002a989eee88 in QObject::~QObject () from /usr/lib/qt3/lib64/libqt-mt.so.3 #31 0x0000002a9589bd30 in ~Account (this=0x964540) at /space/kde/head/src/kdenetwork/kopete/libkopete/kopeteaccount.cpp:105 #32 0x0000002a958b7be4 in ~PasswordedAccount (this=0x964540) at /space/kde/head/src/kdenetwork/kopete/libkopete/kopetepasswordedaccount.cpp:47 #33 0x0000002a9c0b6a9f in ~IRCAccount (this=0x964540) at /space/kde/head/src/kdenetwork/kopete/protocols/irc/ircaccount.cpp:236 #34 0x0000002a989ec190 in QObject::event () from /usr/lib/qt3/lib64/libqt-mt.so.3 #35 0x0000002a98993c2d in QApplication::internalNotify () from /usr/lib/qt3/lib64/libqt-mt.so.3 #36 0x0000002a9899555e in QApplication::notify () from /usr/lib/qt3/lib64/libqt-mt.so.3 #37 0x0000002a97ce06b9 in KApplication::notify (this=0x7fbfffecb0, receiver=0x964540, event=0xf65f90) at /space/kde/head/src/kdelibs/kdecore/kapplication.cpp:549 #38 0x0000002a98994912 in QApplication::sendPostedEvents () from /usr/lib/qt3/lib64/libqt-mt.so.3 #39 0x0000002a9899498d in QApplication::sendPostedEvents () from /usr/lib/qt3/lib64/libqt-mt.so.3 #40 0x0000002a9894b5e0 in QEventLoop::processEvents () from /usr/lib/qt3/lib64/libqt-mt.so.3 #41 0x0000002a989a92f1 in QEventLoop::enterLoop () from /usr/lib/qt3/lib64/libqt-mt.so.3 #42 0x0000002a98995425 in QApplication::enter_loop () from /usr/lib/qt3/lib64/libqt-mt.so.3 #43 0x0000002a98b49974 in QDialog::exec () from /usr/lib/qt3/lib64/libqt-mt.so.3 #44 0x0000002a97701782 in KMessageBox::createKMessageBox ( dialog=0xf73c00, icon=<incomplete type>, text=@0x7fbfffde40, strlist=@0x7fbfffddc0, ask=@0x7fbfffdcc0, checkboxReturn=0x7fbfffdcbf, options=1, details=@0x5d23f0, notifyType=Warning) at /space/kde/head/src/kdelibs/kdeui/kmessagebox.cpp:311 #45 0x0000002a97700e9d in KMessageBox::createKMessageBox ( dialog=0xf73c00, icon=Warning, text=@0x7fbfffde40, strlist=@0x7fbfffddc0, ask=@0x7fbfffdcc0, checkboxReturn=0x7fbfffdcbf, options=1, details=@0x5d23f0) at /space/kde/head/src/kdelibs/kdeui/kmessagebox.cpp:147 #46 0x0000002a97702c68 in KMessageBox::warningContinueCancelListWId ( parent_id=4195926, text=@0x7fbfffde40, strlist=@0x7fbfffddc0, caption=@0x7fbfffde50, buttonContinue=@0x7fbfffde70, dontAskAgainName=@0x7fbfffde80, options=1) at /space/kde/head/src/kdelibs/kdeui/kmessagebox.cpp:648 #47 0x0000002a977029f6 in KMessageBox::warningContinueCancelList ( parent=0x92a0d0, text=@0x7fbfffde40, strlist=@0x7fbfffddc0, caption=@0x7fbfffde50, buttonContinue=@0x7fbfffde70, dontAskAgainName=@0x7fbfffde80, options=1) at /space/kde/head/src/kdelibs/kdeui/kmessagebox.cpp:618 #48 0x0000002a977028fd in KMessageBox::warningContinueCancel ( parent=0x92a0d0, text=@0x7fbfffde40, caption=@0x7fbfffde50, buttonContinue=@0x7fbfffde70, dontAskAgainName=@0x7fbfffde80, options=1) at /space/kde/head/src/kdelibs/kdeui/kmessagebox.cpp:594 #49 0x0000002a9c83f9fe in ChatView::closeView (this=0x92a0d0, force=false) at /space/kde/head/src/kdenetwork/kopete/kopete/chatwindow/chatview.cpp:347 #50 0x0000002a9c849fdc in KopeteChatWindow::closeEvent ( this=0xa3ce30, e=0x7fbfffe2d0) at /space/kde/head/src/kdenetwork/kopete/kopete/chatwindow/kopetechatwindow.cpp:1042 #51 0x0000002a98a1a54b in QWidget::event () from /usr/lib/qt3/lib64/libqt-mt.so.3 #52 0x0000002a98ac8955 in QMainWindow::event () from /usr/lib/qt3/lib64/libqt-mt.so.3 #53 0x0000002a98993c2d in QApplication::internalNotify () from /usr/lib/qt3/lib64/libqt-mt.so.3 #54 0x0000002a9899555e in QApplication::notify () from /usr/lib/qt3/lib64/libqt-mt.so.3 #55 0x0000002a97ce06b9 in KApplication::notify (this=0x7fbfffecb0, receiver=0xa3ce30, event=0x7fbfffe2d0) at /space/kde/head/src/kdelibs/kdecore/kapplication.cpp:549 #56 0x0000002a960c79f4 in QApplication::sendEvent (receiver=0xa3ce30, event=0x7fbfffe2d0) at qapplication.h:515 #57 0x0000002a976b55b7 in KMWSessionManaged::commitData ( this=0x7352a0, sm=@0x6bc160) at /space/kde/head/src/kdelibs/kdeui/kmainwindow.cpp:125 #58 0x0000002a97ce30f9 in KApplication::commitData ( this=0x7fbfffecb0, sm=@0x6bc160) at /space/kde/head/src/kdelibs/kdecore/kapplication.cpp:1214 #59 0x0000000000438b98 in KopeteApplication::commitData ( this=0x7fbfffecb0, sm=@0x6bc160) at /space/kde/head/src/kdenetwork/kopete/kopete/kopeteapplication.cpp:325 #60 0x0000002a9892f9a9 in sm_performSaveYourself () from /usr/lib/qt3/lib64/libqt-mt.so.3 #61 0x0000002a9892fa36 in sm_saveYourselfCallback () from /usr/lib/qt3/lib64/libqt-mt.so.3 #62 0x0000002a99d3b40e in _SmcProcessMessage () from /usr/X11R6/lib64/libSM.so.6 #63 0x0000002a99e4bfc6 in IceProcessMessages () from /usr/X11R6/lib64/libICE.so.6 #64 0x0000002a9892fc7c in QSmSocketReceiver::socketActivated () from /usr/lib/qt3/lib64/libqt-mt.so.3 #65 0x0000002a9892fce3 in QSmSocketReceiver::qt_invoke () from /usr/lib/qt3/lib64/libqt-mt.so.3 #66 0x0000002a989eb909 in QObject::activate_signal () from /usr/lib/qt3/lib64/libqt-mt.so.3 #67 0x0000002a989ebe73 in QObject::activate_signal () from /usr/lib/qt3/lib64/libqt-mt.so.3 #68 0x0000002a98cc6775 in QSocketNotifier::activated () from /usr/lib/qt3/lib64/libqt-mt.so.3 #69 0x0000002a98a0697b in QSocketNotifier::event () from /usr/lib/qt3/lib64/libqt-mt.so.3 #70 0x0000002a98993c2d in QApplication::internalNotify () from /usr/lib/qt3/lib64/libqt-mt.so.3 #71 0x0000002a9899555e in QApplication::notify () from /usr/lib/qt3/lib64/libqt-mt.so.3 #72 0x0000002a97ce06b9 in KApplication::notify (this=0x7fbfffecb0, receiver=0x6be530, event=0x7fbfffe9f0) at /space/kde/head/src/kdelibs/kdecore/kapplication.cpp:549 #73 0x0000002a9898953d in QEventLoop::activateSocketNotifiers () from /usr/lib/qt3/lib64/libqt-mt.so.3 #74 0x0000002a9894bdd5 in QEventLoop::processEvents () from /usr/lib/qt3/lib64/libqt-mt.so.3 #75 0x0000002a989a92f1 in QEventLoop::enterLoop () from /usr/lib/qt3/lib64/libqt-mt.so.3 #76 0x0000002a989a9162 in QEventLoop::exec () from /usr/lib/qt3/lib64/libqt-mt.so.3 #77 0x0000002a98995475 in QApplication::exec () from /usr/lib/qt3/lib64/libqt-mt.so.3 #78 0x0000000000437b88 in main (argc=1, argv=0x7fbffff008) at /space/kde/head/src/kdenetwork/kopete/kopete/main.cpp:99
Created attachment 10055 [details] suggested patch, respecting chatwindows' abort session shutdown needs This patch borrows a bit of code from Kmail so that when the system tray icon is not shown, all kopete windows are responsible for keeping the app running, like Kmail. There is still a problem that on session quit, the plugin manager does not fully complete its shutdown - the plugins are all shut down, but the KopeteApplication destructor is called before the plugins are deleteLater()'d. I'm not sure if the refcount is dropping to 0 (debug output from KApplication::debug() seems to rule this out) or the session manager is killing the app - if anyone has debug techniques to check this please tell me.
this patch seems to work, i had no crash on shutting down kopete anymore
The patch works for me also.
CVS commit by wstephens: Backport fix for crashing on session exit - unload plugins properly. BUG:91288 M +15 -45 kopete/kopeteapplication.cpp 1.192.2.1 M +3 -2 kopete/kopeteapplication.h 1.85.6.1 M +74 -29 kopete/kopetewindow.cpp 1.229.2.1 M +2 -0 kopete/kopetewindow.h 1.79.2.1 M +14 -1 kopete/systemtray.cpp 1.54.4.1 M +1 -1 kopete/chatwindow/Makefile.am 1.17.4.1 M +40 -14 kopete/chatwindow/kopetechatwindow.cpp 1.101.2.1 M +7 -0 kopete/chatwindow/kopetechatwindow.h 1.32.4.1 M +3 -2 libkopete/kopetepluginmanager.cpp 1.42.4.1 M +2 -4 libkopete/kopeteprotocol.cpp 1.91.4.1
What kde version should have the bug fixed? I can still experience it in kde 3.4, Kopete crashes if I logout when msn and icq are still connected. Everything works fine if I logout having disconncted everything first.
>What kde version should have the bug fixed? The bug is still in kde-3.4.0. Gentoo devs have included the patch posted here in the kopete-.3.4.0-r1 ebuild, so bug your distro vendor (or, if you compiled the sources yourself, patch the sources manually). The problem will be definately gone in kde 3.4.1 (unless something really weird happens).
This patch breaks kopete as described in the gentoo bug 91423 (http://bugs.gentoo.org/show_bug.cgi?id=91423) Also discussed as KDE bug 101008 (http://bugs.kde.org/show_bug.cgi?id=101008)
The Bug is the Bug 105442