Bug 36261 - Crash on ClientRegistrar destruction
Summary: Crash on ClientRegistrar destruction
Status: RESOLVED INVALID
Alias: None
Product: Telepathy
Classification: Unclassified
Component: tp-qt (show other bugs)
Version: git master
Hardware: Other All
: medium normal
Assignee: Olli Salli
QA Contact: Telepathy bugs list
URL:
Whiteboard:
Keywords: NEEDINFO
Depends on:
Blocks:
 
Reported: 2011-04-15 07:20 UTC by Alvaro Soliverez
Modified: 2011-07-11 08:22 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
Backtrace of crash (10.96 KB, text/plain)
2011-04-15 09:31 UTC, Alvaro Soliverez
Details

Description Alvaro Soliverez 2011-04-15 07:20:03 UTC
When deleting an object that holds a ClientRegistrar, I'm getting this crash:

There seems to be a problem in ClientRegistrar::unregisterClient()

#0  0xf6c05447 in ?? () from /usr/lib/libQtDBus.so.4
No symbol table info available.
#1  0xf6c057b4 in ?? () from /usr/lib/libQtDBus.so.4
No symbol table info available.
#2  0xf73bd42b in QMetaObject::metacall(QObject*, QMetaObject::Call, int, void**) () from /usr/lib/libQtCore.so.4
No symbol table info available.
#3  0xf73cbd0f in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) () from /usr/lib/libQtCore.so.4
No symbol table info available.
#4  0xf73cc1b4 in QObject::destroyed(QObject*) () from /usr/lib/libQtCore.so.4
No symbol table info available.
#5  0xf73ce44b in QObject::~QObject() () from /usr/lib/libQtCore.so.4
No symbol table info available.
#6  0xf6c04ed9 in QDBusAbstractAdaptor::~QDBusAbstractAdaptor() () from /usr/lib/libQtDBus.so.4
No symbol table info available.
#7  0xe7023651 in ~ClientObserverAdaptor (this=0xf0b313b8, __in_chrg=<value optimized out>) at /root/repo/telepathy-qt4/TelepathyQt4/client-registrar.cpp:109
No locals.
#8  0xe70236b3 in ~ClientObserverAdaptor (this=0xf0b313b8, __in_chrg=<value optimized out>) at /root/repo/telepathy-qt4/TelepathyQt4/client-registrar.cpp:111
No locals.
#9  0xf73ca618 in QObjectPrivate::deleteChildren() () from /usr/lib/libQtCore.so.4
No symbol table info available.
#10 0xf73ce831 in QObject::~QObject() () from /usr/lib/libQtCore.so.4
No symbol table info available.
#11 0xf73cea43 in QObject::~QObject() () from /usr/lib/libQtCore.so.4
No symbol table info available.
#12 0xe7025d73 in Tp::ClientRegistrar::unregisterClient (this=0xf0b2b940, client=...) at /root/repo/telepathy-qt4/TelepathyQt4/client-registrar.cpp:1000
        object = <value optimized out>
        objectPath = {static null = {<No data fields>}, static shared_null = {ref = {_q_value = 10112}, alloc = 0, size = 0, data = 0x804b1f2, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, static shared_empty = {ref = {_q_value = 90}, alloc = 0, size = 0, data = 0xf74f3212, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, d = 0xf0b31788, static codecForCStrings = 0x0}
        busName = {static null = {<No data fields>}, static shared_null = {ref = {_q_value = 10112}, alloc = 0, size = 0, data = 0x804b1f2, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, static shared_empty = {ref = {_q_value = 90}, alloc = 0, size = 0, data = 0xf74f3212, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, d = 0xffffcad8, static codecForCStrings = 0x0}
#13 0xe7025fe7 in Tp::ClientRegistrar::unregisterClients (this=0xf0b2b940) at /root/repo/telepathy-qt4/TelepathyQt4/client-registrar.cpp:1032
        clients = {{d = 0xf0b31b40, e = 0xf0b31b40}}
        end = {i = 0xf0b31b40}
        it = {i = 0xf0b31b68}
#14 0xe7026067 in ~ClientRegistrar (this=0xf0b2b940, __in_chrg=<value optimized out>) at /root/repo/telepathy-qt4/TelepathyQt4/client-registrar.cpp:765
No locals.
#15 0xe70260e3 in ~ClientRegistrar (this=0xf0b2b940, __in_chrg=<value optimized out>) at /root/repo/telepathy-qt4/TelepathyQt4/client-registrar.cpp:767
No locals.
#16 0xf1639c5a in IMPlugin::~IMPlugin() () from /usr/lib/qt4/plugins/MeeGo/Content/libim_panels_plugin.so
No symbol table info available.
#17 0xf1639d13 in IMPlugin::~IMPlugin() () from /usr/lib/qt4/plugins/MeeGo/Content/libim_panels_plugin.so
No symbol table info available.
#18 0xf202e135 in McaFeedPluginContainer::~McaFeedPluginContainer() () from /usr/lib/libmeegouxcontent.so.0
No symbol table info available.
#19 0xf202e1b3 in McaFeedPluginContainer::~McaFeedPluginContainer() () from /usr/lib/libmeegouxcontent.so.0
No symbol table info available.
#20 0xf2024f15 in McaFeedManager::removePlugin(McaFeedPluginContainer*) () from /usr/lib/libmeegouxcontent.so.0
No symbol table info available.
#21 0xf2025ecd in McaFeedManager::~McaFeedManager() () from /usr/lib/libmeegouxcontent.so.0
No symbol table info available.
#22 0xf2025fe3 in McaFeedManager::~McaFeedManager() () from /usr/lib/libmeegouxcontent.so.0
No symbol table info available.
#23 0xf2023788 in McaFeedManager::releaseManager() () from /usr/lib/libmeegouxcontent.so.0
No symbol table info available.
#24 0xf202fe94 in McaAbstractManager::~McaAbstractManager() () from /usr/lib/libmeegouxcontent.so.0
No symbol table info available.
#25 0xf2028283 in McaPanelManager::~McaPanelManager() () from /usr/lib/libmeegouxcontent.so.0
No symbol table info available.
#26 0xf205aa96 in QDeclarativePrivate::QDeclarativeElement<McaPanelManager>::~QDeclarativeElement() () from /usr/lib/qt4/imports/MeeGo/Content/libContent.so
No symbol table info available.
#27 0xf73ca618 in QObjectPrivate::deleteChildren() () from /usr/lib/libQtCore.so.4
No symbol table info available.
#28 0xf73ce831 in QObject::~QObject() () from /usr/lib/libQtCore.so.4
No symbol table info available.
#29 0xf6d52ad2 in QDeclarativeItem::~QDeclarativeItem() () from /usr/lib/libQtDeclarative.so.4
No symbol table info available.
#30 0xf6d33788 in ?? () from /usr/lib/libQtDeclarative.so.4
No symbol table info available.
#31 0xf6d18ed2 in ?? () from /usr/lib/libQtDeclarative.so.4
No symbol table info available.
#32 0xf7c79b26 in QGraphicsItem::~QGraphicsItem() () from /usr/lib/libQtGui.so.4
No symbol table info available.
#33 0xf6d52ac7 in QDeclarativeItem::~QDeclarativeItem() () from /usr/lib/libQtDeclarative.so.4
No symbol table info available.
#34 0xf6d59af3 in ?? () from /usr/lib/libQtDeclarative.so.4
No symbol table info available.
#35 0xf6d18a52 in ?? () from /usr/lib/libQtDeclarative.so.4
No symbol table info available.
#36 0xf73c97b6 in qDeleteInEventHandler(QObject*) () from /usr/lib/libQtCore.so.4
No symbol table info available.
#37 0xf73cb888 in QObject::event(QEvent*) () from /usr/lib/libQtCore.so.4
No symbol table info available.
#38 0xf6d4cd82 in QDeclarativeItem::event(QEvent*) () from /usr/lib/libQtDeclarative.so.4
No symbol table info available.
#39 0xf763e2bc in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib/libQtGui.so.4
No symbol table info available.
#40 0xf7642e9e in QApplication::notify(QObject*, QEvent*) () from /usr/lib/libQtGui.so.4
No symbol table info available.
#41 0xf73b70a3 in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib/libQtCore.so.4
No symbol table info available.
#42 0xf73baad5 in QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) () from /usr/lib/libQtCore.so.4
No symbol table info available.
#43 0xf73bacae in QCoreApplication::sendPostedEvents(QObject*, int) () from /usr/lib/libQtCore.so.4
No symbol table info available.
#44 0xf73e3565 in ?? () from /usr/lib/libQtCore.so.4
No symbol table info available.
#45 0xf6948afb in g_main_context_dispatch () from /lib/libglib-2.0.so.0
No symbol table info available.
#46 0xf694911f in ?? () from /lib/libglib-2.0.so.0
No symbol table info available.
#47 0xf69492e2 in g_main_context_iteration () from /lib/libglib-2.0.so.0
No symbol table info available.
#48 0xf73e36dd in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
No symbol table info available.
#49 0xf76ee406 in ?? () from /usr/lib/libQtGui.so.4
No symbol table info available.
#50 0xf73b623a in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
No symbol table info available.
#51 0xf73b64ea in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
No symbol table info available.
#52 0xf73bad74 in QCoreApplication::exec() () from /usr/lib/libQtCore.so.4
No symbol table info available.
#53 0xf763c328 in QApplication::exec() () from /usr/lib/libQtGui.so.4
No symbol table info available.
#54 0x080499ef in ?? ()
No symbol table info available.
#55 0xf6fcebb7 in __libc_start_main () from /lib/libc.so.6
No symbol table info available.
#56 0x08049491 in ?? ()
No symbol table info available.
Comment 1 Olli Salli 2011-04-15 08:24:33 UTC
Please repost backtrace with Qt debug symbols installed. If possible, could you also please attach a minimal test program which exhibits this problem? If you unregister all of the clients first, and only then destroy the client registrar, do you have this issue?
Comment 2 Alvaro Soliverez 2011-04-15 09:31:01 UTC
It is not easily reproduceable in a stand-alone application. This happens in a plugin called by an application that is included in another application of MeeGo Tablet.

I'm attaching a backtrace with the installed symbols.
Comment 3 Alvaro Soliverez 2011-04-15 09:31:51 UTC
Created attachment 45677 [details]
Backtrace of crash
Comment 4 Alvaro Soliverez 2011-04-15 11:00:10 UTC
Some further debug:
- The ClientRegistrar has two clients, an Observer and an Approver.
- I've added code to unregister the clients manually. The crash happens the first time it tries to unregister either of the clients. I tested by changing the order, but it crashes always on the first call.
Comment 5 Alvaro Soliverez 2011-04-19 10:08:00 UTC
The problem seems to be in the way QDBusAbstractAdaptor handles the destruction. Several other projects have hit this problem and had to work around it by using deleteLater() or similar.

See this, for example: http://web.archiveorange.com/archive/v/yEWOGArCSndvhyaSDKUr

I've tried using deleteLater in ClientRegistrar, but it keeps crashing in various places.
Comment 6 Alvaro Soliverez 2011-04-19 17:56:55 UTC
Here's a bug on KDE, with a patch that addresses the issue, plus links to Qt's answer to the bug: https://bugs.kde.org/show_bug.cgi?id=234484

It seems to be fixed in Qt 4.8, but that's not relief to us atm.
Comment 7 Alvaro Soliverez 2011-07-11 08:22:37 UTC
The original problem was a misbehaviour of the thread where this was instantiated. Closing this bug.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.