Bug 325955

Summary: Kontact segfaulted after showing a message about being unable to aquire a lock
Product: [Applications] kontact Reporter: Dennis Schridde <heri+kde>
Component: generalAssignee: kdepim bugs <kdepim-bugs>
Status: RESOLVED UNMAINTAINED    
Severity: crash Keywords: drkonqi
Priority: NOR    
Version: 4.11.2   
Target Milestone: ---   
Platform: Gentoo Packages   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Dennis Schridde 2013-10-13 10:12:32 UTC
Application: kontact (4.11.2)
KDE Platform Version: 4.11.2
Qt Version: 4.8.5
Operating System: Linux 3.11.4-gentoo x86_64
Distribution: "Gentoo Base System release 2.2"

-- Information about the crash:
- What I was doing when the application crashed:
I started Kontact and was about to open a mailbox, when I received a message about the email program being unable to aquire a lock due to a timeout. After clicking OK, Kontact segfaulted. (Note that this is different from a bug I reported just minutes ago, where Kontact *aborted* after I clicked OK: bug #325954)


- Unusual behavior I noticed:
The message box I received just before Kontact segfaulted:
---
Im E-Mail-Programm ist ein schwerwiegender Fehler aufgetreten. Das Programm wird beendet.
Die Fehlermeldung lautet:
Zeitüberschreitung beim Erhalten der Sperre.
---

Rough translation: Serious error in the email program. It will be closed. The error message was: Timeout while aquiring the lock.

The crash can be reproduced sometimes.

-- Backtrace:
Application: Kontact (kontact), signal: Segmentation fault
Using host libthread_db library "/lib64/libthread_db.so.1".
[Current thread is 1 (Thread 0x7ff62bf86780 (LWP 27659))]

Thread 6 (Thread 0x7ff626d85700 (LWP 27664)):
#0  0x0000003a0480b8b4 in pthread_cond_wait () from /lib64/libpthread.so.0
#1  0x00000036aad39b42 in ?? () from /usr/lib64/qt4/libQtWebKit.so.4
#2  0x00000036aad39b79 in ?? () from /usr/lib64/qt4/libQtWebKit.so.4
#3  0x0000003a04807dff in start_thread () from /lib64/libpthread.so.0
#4  0x0000003a040e701d in clone () from /lib64/libc.so.6

Thread 5 (Thread 0x7ff626484700 (LWP 27665)):
#0  0x0000003f7a087ad9 in ?? () from /usr/lib64/libglib-2.0.so.0
#1  0x0000003f7a087e09 in g_mutex_unlock () from /usr/lib64/libglib-2.0.so.0
#2  0x0000003f7a0488d6 in ?? () from /usr/lib64/libglib-2.0.so.0
#3  0x0000003f7a048ad4 in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#4  0x00000032895aa2ce in QEventDispatcherGlib::processEvents (this=0x7ff6200008c0, flags=...) at kernel/qeventdispatcher_glib.cpp:427
#5  0x000000328957badf in QEventLoop::processEvents (this=this@entry=0x7ff626483e60, flags=...) at kernel/qeventloop.cpp:149
#6  0x000000328957bdcd in QEventLoop::exec (this=this@entry=0x7ff626483e60, flags=...) at kernel/qeventloop.cpp:204
#7  0x0000003289479860 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:536
#8  0x000000328947c0ff in QThreadPrivate::start (arg=0xd563d0) at thread/qthread_unix.cpp:338
#9  0x0000003a04807dff in start_thread () from /lib64/libpthread.so.0
#10 0x0000003a040e701d in clone () from /lib64/libc.so.6

Thread 4 (Thread 0x7ff5d3fff700 (LWP 27673)):
#0  0x0000003a0480bc61 in pthread_cond_timedwait () from /lib64/libpthread.so.0
#1  0x000000328947c5bc in wait (time=30000, this=0x13bcbf0) at thread/qwaitcondition_unix.cpp:84
#2  QWaitCondition::wait (this=<optimized out>, mutex=mutex@entry=0x13bdeb8, time=30000) at thread/qwaitcondition_unix.cpp:158
#3  0x000000328946f4ec in QThreadPoolThread::run (this=0x13c0550) at concurrent/qthreadpool.cpp:141
#4  0x000000328947c0ff in QThreadPrivate::start (arg=0x13c0550) at thread/qthread_unix.cpp:338
#5  0x0000003a04807dff in start_thread () from /lib64/libpthread.so.0
#6  0x0000003a040e701d in clone () from /lib64/libc.so.6

Thread 3 (Thread 0x7ff5d0a20700 (LWP 27694)):
[KCrash Handler]
#6  QHash<QUrl, QVariant::Type>::findNode (this=this@entry=0x10, akey=..., ahp=ahp@entry=0x0) at /usr/include/qt4/QtCore/qhash.h:884
#7  0x000000328e05a621 in constFind (akey=..., this=0x10) at /usr/include/qt4/QtCore/qhash.h:861
#8  typeFromDataTypeUri (dataTypeUri=..., this=0x0) at /var/tmp/portage/dev-libs/soprano-2.9.3/work/soprano-2.9.3/soprano/literalvalue.cpp:95
#9  Soprano::LiteralValue::typeFromDataTypeUri (dataTypeUri=...) at /var/tmp/portage/dev-libs/soprano-2.9.3/work/soprano-2.9.3/soprano/literalvalue.cpp:812
#10 0x000000328e05a707 in Soprano::LiteralValue::fromString (value=..., type=...) at /var/tmp/portage/dev-libs/soprano-2.9.3/work/soprano-2.9.3/soprano/literalvalue.cpp:730
#11 0x00007ff5da005365 in Soprano::ODBC::QueryResult::getData (this=<optimized out>, colNum=colNum@entry=2) at /var/tmp/portage/dev-libs/soprano-2.9.3/work/soprano-2.9.3/backends/virtuoso/odbcqueryresult.cpp:205
#12 0x00007ff5d9ffe491 in Soprano::Virtuoso::QueryResultIteratorBackend::next (this=0x7ff5c8024940) at /var/tmp/portage/dev-libs/soprano-2.9.3/work/soprano-2.9.3/backends/virtuoso/virtuosoqueryresultiteratorbackend.cpp:146
#13 0x00000036ab85577e in Soprano::Iterator<Soprano::BindingSet>::next (this=0x7ff5d0a1fc70) at /usr/include/soprano/iterator.h:239
#14 0x00000036ab84f8ef in Nepomuk2::ResourceData::load (this=this@entry=0x7ff5c8002e60) at /var/tmp/portage/kde-base/nepomuk-core-4.11.2/work/nepomuk-core-4.11.2/libnepomukcore/resource/resourcedata.cpp:370
#15 0x00000036ab85096e in Nepomuk2::ResourceData::property (this=0x7ff5c8002e60, uri=...) at /var/tmp/portage/kde-base/nepomuk-core-4.11.2/work/nepomuk-core-4.11.2/libnepomukcore/resource/resourcedata.cpp:242
#16 0x00000036ab85c388 in Nepomuk2::Resource::property (this=this@entry=0x7ff5d0a1fdd0, uri=...) at /var/tmp/portage/kde-base/nepomuk-core-4.11.2/work/nepomuk-core-4.11.2/libnepomukcore/resource/resource.cpp:268
#17 0x00007ff5dde14b45 in MessageCore::NepomukResourceRetrieverRunnable::run (this=0x1cb8210) at /var/tmp/portage/kde-base/kdepim-common-libs-4.11.2/work/kdepim-common-libs-4.11.2/messagecore/nepomukutil/asyncnepomukresourceretriever.cpp:50
#18 0x000000328946f3f2 in QThreadPoolThread::run (this=0x1a06870) at concurrent/qthreadpool.cpp:107
#19 0x000000328947c0ff in QThreadPrivate::start (arg=0x1a06870) at thread/qthread_unix.cpp:338
#20 0x0000003a04807dff in start_thread () from /lib64/libpthread.so.0
#21 0x0000003a040e701d in clone () from /lib64/libc.so.6

Thread 2 (Thread 0x7ff5c3fff700 (LWP 27695)):
#0  0x0000003a0480bc61 in pthread_cond_timedwait () from /lib64/libpthread.so.0
#1  0x000000328947c5bc in wait (time=30000, this=0x1408f50) at thread/qwaitcondition_unix.cpp:84
#2  QWaitCondition::wait (this=<optimized out>, mutex=mutex@entry=0x1408ec8, time=30000) at thread/qwaitcondition_unix.cpp:158
#3  0x000000328946f4ec in QThreadPoolThread::run (this=0x19f1c60) at concurrent/qthreadpool.cpp:141
#4  0x000000328947c0ff in QThreadPrivate::start (arg=0x19f1c60) at thread/qthread_unix.cpp:338
#5  0x0000003a04807dff in start_thread () from /lib64/libpthread.so.0
#6  0x0000003a040e701d in clone () from /lib64/libc.so.6

Thread 1 (Thread 0x7ff62bf86780 (LWP 27659)):
#0  0x0000003a0480b8b4 in pthread_cond_wait () from /lib64/libpthread.so.0
#1  0x000000328947c5de in wait (time=18446744073709551615, this=0x1a064b0) at thread/qwaitcondition_unix.cpp:86
#2  QWaitCondition::wait (this=this@entry=0x1a060c0, mutex=mutex@entry=0x1a06098, time=time@entry=18446744073709551615) at thread/qwaitcondition_unix.cpp:158
#3  0x000000328946ed92 in QThreadPoolPrivate::waitForDone (this=0x1a06010, msecs=msecs@entry=-1) at concurrent/qthreadpool.cpp:298
#4  0x000000328947023d in QThreadPool::~QThreadPool (this=0x19f6c68, __in_chrg=<optimized out>) at concurrent/qthreadpool.cpp:440
#5  0x00007ff5dde13859 in ~AsyncNepomukResourceRetrieverPrivate (this=<optimized out>, __in_chrg=<optimized out>) at /var/tmp/portage/kde-base/kdepim-common-libs-4.11.2/work/kdepim-common-libs-4.11.2/messagecore/nepomukutil/asyncnepomukresourceretriever.cpp:61
#6  MessageCore::AsyncNepomukResourceRetriever::~AsyncNepomukResourceRetriever (this=0x1a06590, __in_chrg=<optimized out>) at /var/tmp/portage/kde-base/kdepim-common-libs-4.11.2/work/kdepim-common-libs-4.11.2/messagecore/nepomukutil/asyncnepomukresourceretriever.cpp:131
#7  0x00007ff5dd821642 in ~CallbackNepomukResourceRetriever (this=0x1a06590, __in_chrg=<optimized out>) at /var/tmp/portage/kde-base/kdepim-common-libs-4.11.2/work/kdepim-common-libs-4.11.2/messagelist/core/callbacknepomukresourceretriever.h:32
#8  MessageList::CallbackNepomukResourceRetriever::~CallbackNepomukResourceRetriever (this=0x1a06590, __in_chrg=<optimized out>) at /var/tmp/portage/kde-base/kdepim-common-libs-4.11.2/work/kdepim-common-libs-4.11.2/messagelist/core/callbacknepomukresourceretriever.h:32
#9  0x0000003a040379e9 in __run_exit_handlers () from /lib64/libc.so.6
#10 0x0000003a04037a65 in exit () from /lib64/libc.so.6
#11 0x00007ff5de1220c8 in MailCommon::Kernel::emergencyExit (this=this@entry=0x11930c0, reason=...) at /var/tmp/portage/kde-base/kmail-4.11.2/work/kmail-4.11.2/mailcommon/kernel/mailkernel.cpp:228
#12 0x00007ff5de122675 in MailCommon::Kernel::createDefaultCollectionDone (this=0x11930c0, job=0x11cfad0) at /var/tmp/portage/kde-base/kmail-4.11.2/work/kmail-4.11.2/mailcommon/kernel/mailkernel.cpp:182
#13 0x0000003289590f38 in QMetaObject::activate (sender=sender@entry=0x11cfad0, m=m@entry=0x39230bc4a0 <KJob::staticMetaObject>, local_signal_index=local_signal_index@entry=3, argv=argv@entry=0x7fff811adb60) at kernel/qobject.cpp:3547
#14 0x0000003922d32d32 in KJob::result (this=this@entry=0x11cfad0, _t1=_t1@entry=0x11cfad0) at /var/tmp/portage/kde-base/kdelibs-4.11.2-r1/work/kdelibs-4.11.2_build/kdecore/kjob.moc:207
#15 0x0000003922d32d70 in KJob::emitResult (this=0x11cfad0) at /var/tmp/portage/kde-base/kdelibs-4.11.2-r1/work/kdelibs-4.11.2/kdecore/jobs/kjob.cpp:318
#16 0x00007ff62d9a1ca0 in Akonadi::SpecialCollectionsRequestJobPrivate::lockResult (this=0x1151830, job=0x164df10) at /var/tmp/portage/kde-base/kdepimlibs-4.11.2-r1/work/kdepimlibs-4.11.2/akonadi/specialcollectionsrequestjob.cpp:121
#17 0x0000003289590f38 in QMetaObject::activate (sender=sender@entry=0x164df10, m=m@entry=0x39230bc4a0 <KJob::staticMetaObject>, local_signal_index=local_signal_index@entry=3, argv=argv@entry=0x7fff811add30) at kernel/qobject.cpp:3547
#18 0x0000003922d32d32 in KJob::result (this=this@entry=0x164df10, _t1=_t1@entry=0x164df10) at /var/tmp/portage/kde-base/kdelibs-4.11.2-r1/work/kdelibs-4.11.2_build/kdecore/kjob.moc:207
#19 0x0000003922d32d70 in KJob::emitResult (this=0x164df10) at /var/tmp/portage/kde-base/kdelibs-4.11.2-r1/work/kdelibs-4.11.2/kdecore/jobs/kjob.cpp:318
#20 0x00007ff62d99b402 in Akonadi::GetLockJob::Private::timeout (this=0xe13190) at /var/tmp/portage/kde-base/kdepimlibs-4.11.2-r1/work/kdepimlibs-4.11.2/akonadi/specialcollectionshelperjobs.cpp:613
#21 0x0000003289590f38 in QMetaObject::activate (sender=0x1636ac0, m=<optimized out>, local_signal_index=<optimized out>, argv=0x0) at kernel/qobject.cpp:3547
#22 0x00000032895951d9 in QObject::event (this=0x1636ac0, e=<optimized out>) at kernel/qobject.cpp:1156
#23 0x00000036a8bcb05c in QApplicationPrivate::notify_helper (this=this@entry=0xb498f0, receiver=receiver@entry=0x1636ac0, e=e@entry=0x7fff811ae270) at kernel/qapplication.cpp:4562
#24 0x00000036a8bd16d8 in QApplication::notify (this=this@entry=0x7fff811ae600, receiver=receiver@entry=0x1636ac0, e=e@entry=0x7fff811ae270) at kernel/qapplication.cpp:4348
#25 0x00000036a6c406fb in KApplication::notify (this=0x7fff811ae600, receiver=0x1636ac0, event=0x7fff811ae270) at /var/tmp/portage/kde-base/kdelibs-4.11.2-r1/work/kdelibs-4.11.2/kdeui/kernel/kapplication.cpp:311
#26 0x000000328957cecc in QCoreApplication::notifyInternal (this=0x7fff811ae600, receiver=0x1636ac0, event=0x7fff811ae270) at kernel/qcoreapplication.cpp:949
#27 0x00000032895acdcb in sendEvent (event=<optimized out>, receiver=<optimized out>) at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:231
#28 QTimerInfoList::activateTimers (this=0xb482d0) at kernel/qeventdispatcher_unix.cpp:621
#29 0x00000032895aa081 in timerSourceDispatch (source=<optimized out>) at kernel/qeventdispatcher_glib.cpp:186
#30 0x0000003f7a0486d5 in g_main_context_dispatch () from /usr/lib64/libglib-2.0.so.0
#31 0x0000003f7a048a28 in ?? () from /usr/lib64/libglib-2.0.so.0
#32 0x0000003f7a048ad4 in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#33 0x00000032895aa2b3 in QEventDispatcherGlib::processEvents (this=0xb0cb00, flags=...) at kernel/qeventdispatcher_glib.cpp:425
#34 0x00000036a8c6a20e in QGuiEventDispatcherGlib::processEvents (this=<optimized out>, flags=...) at kernel/qguieventdispatcher_glib.cpp:204
#35 0x000000328957badf in QEventLoop::processEvents (this=this@entry=0x7fff811ae500, flags=...) at kernel/qeventloop.cpp:149
#36 0x000000328957bdcd in QEventLoop::exec (this=this@entry=0x7fff811ae500, flags=...) at kernel/qeventloop.cpp:204
#37 0x0000003289581009 in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1221
#38 0x00000036a8bc960c in QApplication::exec () at kernel/qapplication.cpp:3823
#39 0x0000000000403740 in main (argc=1, argv=0x7fff811ae748) at /var/tmp/portage/kde-base/kontact-4.11.2/work/kontact-4.11.2/kontact/src/main.cpp:219

Reported using DrKonqi
Comment 1 Dennis Schridde 2013-10-13 10:19:16 UTC
Possibly related bugs:
* bug #325954: Same message just before the crash
* bug # - b.k.o search times out, and Kontact is not operational anymore, thus I cannot give you the exact number: Kontact leaves a process behind after being closed and thus cannot be opened again - maybe that is related to some locking mechanism?
Comment 2 Dennis Schridde 2013-10-13 10:28:04 UTC
After restarting Akonadi (akonadictl restart), this did not happen again.
Comment 3 Dennis Schridde 2013-10-13 10:29:08 UTC
(In reply to comment #1)
> Possibly related bugs:
> * bug #325954: Same message just before the crash
> * bug # - b.k.o search times out, and Kontact is not operational anymore,
> thus I cannot give you the exact number: Kontact leaves a process behind
> after being closed and thus cannot be opened again - maybe that is related
> to some locking mechanism?

That was bug #227636.
Comment 4 Denis Kurz 2016-09-24 19:26:02 UTC
This bug has only been reported for versions before 4.14, which have been unsupported for at least two years now. Can anyone tell if this bug still present?

If noone confirms this bug for a Framework-based version of kontact (version 5.0 or later, as part of KDE Applications 15.08 or later), it gets closed in about three months.
Comment 5 Denis Kurz 2017-01-07 22:43:04 UTC
Just as announced in my last comment, I close this bug. If you encounter it again in a recent version (at least 5.0 aka 15.08), please open a new one unless it already exists. Thank you for all your input.