Bug 281402

Summary: Akonadi agent crash whe sending email
Product: [Frameworks and Libraries] Akonadi Reporter: Petr Gebauer <pege2>
Component: Mail Dispatcher AgentAssignee: kdepim bugs <kdepim-bugs>
Status: RESOLVED DUPLICATE    
Severity: crash CC: amandine.verguet, carl.erwin, fire, mhitzelberger, nemeskey.david, ultrabla, vkrause, winter
Priority: NOR    
Version: 4.7   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: New crash information added by DrKonqi
New crash information added by DrKonqi

Description Petr Gebauer 2011-09-05 14:04:43 UTC
Application: akonadi_maildispatcher_agent (4.7)
KDE Platform Version: 4.7.00 (4.7.0) (Compiled from sources)
Qt Version: 4.7.3
Operating System: Linux 3.1.0-rc4 x86_64
Distribution (Platform): Gentoo Packages

-- Information about the crash:
- What I was doing when the application crashed:
I was trying to send email, agent segfaults for 3 times. It looks like null pointer dereference.

-- Backtrace:
Application: Akonadi Agent (akonadi_maildispatcher_agent), signal: Segmentation fault
[KCrash Handler]
#6  0x00007fd0520554a4 in QHash<QString, KIO::HostQueue>::detach (this=0x80) at /usr/include/qt4/QtCore/qhash.h:299
#7  0x00007fd0520581b8 in QHash<QString, KIO::HostQueue>::operator[] (this=0x80, akey=...) at /usr/include/qt4/QtCore/qhash.h:738
#8  0x00007fd052050da2 in KIO::ProtoQueue::removeJob (this=0x0, job=0xe509e0) at /var/tmp/paludis/kde-base-kdelibs-4.7.0-r1/work/kdelibs-4.7.0/kio/kio/scheduler.cpp:483
#9  0x00007fd05205108a in KIO::SchedulerPrivate::assignJobToSlave (this=<optimized out>, slave=0xe64510, job=0xe509e0) at /var/tmp/paludis/kde-base-kdelibs-4.7.0-r1/work/kdelibs-4.7.0/kio/kio/scheduler.cpp:1273
#10 0x00007fd054861f60 in MailTransport::SmtpJob::startSmtpJob (this=0xe58270) at /var/tmp/paludis/kde-base-kdepimlibs-4.7.0/work/kdepimlibs-4.7.0/mailtransport/smtpjob.cpp:239
#11 0x00007fd0548626a6 in MailTransport::SmtpJob::doStart (this=0xe58270) at /var/tmp/paludis/kde-base-kdepimlibs-4.7.0/work/kdepimlibs-4.7.0/mailtransport/smtpjob.cpp:129
#12 0x00007fd05485f584 in MailTransport::TransportJob::start (this=0xe58270) at /var/tmp/paludis/kde-base-kdepimlibs-4.7.0/work/kdepimlibs-4.7.0/mailtransport/transportjob.cpp:129
#13 0x00000000004155e9 in SendJob::Private::doTraditionalTransport (this=<optimized out>) at /var/tmp/paludis/kde-base-kdepim-runtime-4.7.0/work/kdepim-runtime-4.7.0/agents/maildispatcher/sendjob.cpp:197
#14 0x0000000000415815 in SendJob::Private::doTransport (this=0xe3dc70) at /var/tmp/paludis/kde-base-kdepim-runtime-4.7.0/work/kdepim-runtime-4.7.0/agents/maildispatcher/sendjob.cpp:130
#15 0x0000000000415a3e in SendJob::qt_metacall (this=0xe296c0, _c=QMetaObject::InvokeMetaMethod, _id=<optimized out>, _a=0xe529d0) at /var/tmp/paludis/kde-base-kdepim-runtime-4.7.0/work/kdepim-runtime-4.7.0_build/agents/maildispatcher/sendjob.moc:85
#16 0x00007fd05561cc6a in QObject::event (this=0xe296c0, e=<optimized out>) at kernel/qobject.cpp:1217
#17 0x00007fd0533b38d4 in QApplicationPrivate::notify_helper (this=0xcc08b0, receiver=0xe296c0, e=0xe3e080) at kernel/qapplication.cpp:4462
#18 0x00007fd0533b8bd1 in QApplication::notify (this=<optimized out>, receiver=0xe296c0, e=0xe3e080) at kernel/qapplication.cpp:4341
#19 0x00007fd054167062 in KApplication::notify (this=0x7fff4faed580, receiver=0xe296c0, event=0xe3e080) at /var/tmp/paludis/kde-base-kdelibs-4.7.0-r1/work/kdelibs-4.7.0/kdeui/kernel/kapplication.cpp:311
#20 0x00007fd05560686b in QCoreApplication::notifyInternal (this=0x7fff4faed580, receiver=0xe296c0, event=0xe3e080) at kernel/qcoreapplication.cpp:731
#21 0x00007fd05560a77e in sendEvent (event=0xe3e080, receiver=0xe296c0) at kernel/qcoreapplication.h:215
#22 QCoreApplicationPrivate::sendPostedEvents (receiver=0x0, event_type=0, data=0xca7380) at kernel/qcoreapplication.cpp:1372
#23 0x00007fd055634823 in sendPostedEvents () at kernel/qcoreapplication.h:220
#24 postEventSourceDispatch (s=<optimized out>) at kernel/qeventdispatcher_glib.cpp:277
#25 0x00007fd0512e305e in g_main_dispatch (context=0xcc3c40) at gmain.c:2441
#26 g_main_context_dispatch (context=0xcc3c40) at gmain.c:3014
#27 0x00007fd0512e3848 in g_main_context_iterate (context=0xcc3c40, block=1, dispatch=1, self=<optimized out>) at gmain.c:3092
#28 0x00007fd0512e3add in g_main_context_iteration (context=0xcc3c40, may_block=1) at gmain.c:3155
#29 0x00007fd0556349bf in QEventDispatcherGlib::processEvents (this=0xcbce60, flags=<optimized out>) at kernel/qeventdispatcher_glib.cpp:422
#30 0x00007fd05346412e in QGuiEventDispatcherGlib::processEvents (this=<optimized out>, flags=<optimized out>) at kernel/qguieventdispatcher_glib.cpp:204
#31 0x00007fd055605312 in QEventLoop::processEvents (this=<optimized out>, flags=...) at kernel/qeventloop.cpp:149
#32 0x00007fd055605555 in QEventLoop::exec (this=0x7fff4faed4e0, flags=...) at kernel/qeventloop.cpp:201
#33 0x00007fd05560aa79 in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1008
#34 0x00007fd055c26ffe in Akonadi::AgentBase::init (r=0xe020b0) at /var/tmp/paludis/kde-base-kdepimlibs-4.7.0/work/kdepimlibs-4.7.0/akonadi/agentbase.cpp:539
#35 0x000000000040da25 in Akonadi::AgentBase::init<MailDispatcherAgent> (argc=<optimized out>, argv=<optimized out>) at /usr/include/KDE/Akonadi/../../akonadi/agentbase.h:342
#36 0x00007fd05295febd in __libc_start_main (main=0x40c200 <main(int, char**)>, argc=3, ubp_av=0x7fff4faed6a8, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7fff4faed698) at libc-start.c:226
#37 0x000000000040ac49 in _start () at ../sysdeps/x86_64/elf/start.S:113

Reported using DrKonqi
Comment 1 Amandine 2011-10-23 10:00:55 UTC
Crash occurs when mail has just been sent.
Kde 4.7.2 Archlinux. Gdb and valgrind traces attached. No kde debug package available on my distribution, sorry.

[KCrash Handler]
#6  0x00007ff913333f44 in ?? () from /usr/lib/libakonadi-kde.so.4
#7  0x00007ff913333ffe in Akonadi::Entity::operator=(Akonadi::Entity const&) () from /usr/lib/libakonadi-kde.so.4
#8  0x00000000004168b9 in ?? ()
#9  0x00000000004169c5 in ?? ()
#10 0x00007ff912d575ea in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) () from /usr/lib/libQtCore.so.4
#11 0x00007ff9125ce722 in KJob::result(KJob*) () from /usr/lib/libkdecore.so.5
#12 0x00007ff9125ce760 in KJob::emitResult() () from /usr/lib/libkdecore.so.5
#13 0x00007ff9133f164d in Akonadi::Job::qt_metacall(QMetaObject::Call, int, void**) () from /usr/lib/libakonadi-kde.so.4
#14 0x00007ff91336dcf5 in Akonadi::CollectionFetchJob::qt_metacall(QMetaObject::Call, int, void**) () from /usr/lib/libakonadi-kde.so.4
#15 0x00007ff912d5b18e in QObject::event(QEvent*) () from /usr/lib/libQtCore.so.4
#16 0x00007ff910a27ae4 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib/libQtGui.so.4
#17 0x00007ff910a2c951 in QApplication::notify(QObject*, QEvent*) () from /usr/lib/libQtGui.so.4
#18 0x00007ff911743bb6 in KApplication::notify(QObject*, QEvent*) () from /usr/lib/libkdeui.so.5
#19 0x00007ff912d4489c in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib/libQtCore.so.4
#20 0x00007ff912d47c2f in QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) () from /usr/lib/libQtCore.so.4
#21 0x00007ff912d6f1a3 in ?? () from /usr/lib/libQtCore.so.4
#22 0x00007ff90e3b485d in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
#23 0x00007ff90e3b5058 in ?? () from /usr/lib/libglib-2.0.so.0
#24 0x00007ff90e3b5229 in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
#25 0x00007ff912d6f606 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#26 0x00007ff910acaeee in ?? () from /usr/lib/libQtGui.so.4
#27 0x00007ff912d43a92 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#28 0x00007ff912d43c97 in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#29 0x00007ff912d47eab in QCoreApplication::exec() () from /usr/lib/libQtCore.so.4
#30 0x00007ff91333daf6 in Akonadi::AgentBase::init(Akonadi::AgentBase*) () from /usr/lib/libakonadi-kde.so.4
#31 0x000000000040bfc3 in int Akonadi::AgentBase::init<MailDispatcherAgent>(int, char**) ()
#32 0x00007ff91000b13d in __libc_start_main () from /lib/libc.so.6
#33 0x0000000000409115 in _start ()

==12543== Invalid read of size 8
==12543==    at 0x4168AF: ??? (in /usr/bin/akonadi_maildispatcher_agent)
==12543==    by 0x4169C4: ??? (in /usr/bin/akonadi_maildispatcher_agent)
==12543==    by 0x561C5E9: QMetaObject::activate(QObject*, QMetaObject const*, int, void**) (in /usr/lib/libQtCore.so.4.7.4)
==12543==    by 0x5CF0721: KJob::result(KJob*) (in /usr/lib/libkdecore.so.5.7.0)
==12543==    by 0x5CF075F: KJob::emitResult() (in /usr/lib/libkdecore.so.5.7.0)
==12543==    by 0x4F6164C: Akonadi::Job::qt_metacall(QMetaObject::Call, int, void**) (in /usr/lib/libakonadi-kde.so.4.7.0)
==12543==    by 0x4EDDCF4: Akonadi::CollectionFetchJob::qt_metacall(QMetaObject::Call, int, void**) (in /usr/lib/libakonadi-kde.so.4.7.0)
==12543==    by 0x562018D: QObject::event(QEvent*) (in /usr/lib/libQtCore.so.4.7.4)
==12543==    by 0x71E9AE3: QApplicationPrivate::notify_helper(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.7.4)
==12543==    by 0x71EE950: QApplication::notify(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.7.4)
==12543==    by 0x6BF5BB5: KApplication::notify(QObject*, QEvent*) (in /usr/lib/libkdeui.so.5.7.0)
==12543==    by 0x560989B: QCoreApplication::notifyInternal(QObject*, QEvent*) (in /usr/lib/libQtCore.so.4.7.4)
==12543==  Address 0x12a7ddc8 is 0 bytes after a block of size 24 alloc'd
==12543==    at 0x4C2640D: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==12543==    by 0x554024A: QListData::detach(int) (in /usr/lib/libQtCore.so.4.7.4)
==12543==    by 0x4172FB: ??? (in /usr/bin/akonadi_maildispatcher_agent)
==12543==    by 0x4168A2: ??? (in /usr/bin/akonadi_maildispatcher_agent)
==12543==    by 0x4169C4: ??? (in /usr/bin/akonadi_maildispatcher_agent)
==12543==    by 0x561C5E9: QMetaObject::activate(QObject*, QMetaObject const*, int, void**) (in /usr/lib/libQtCore.so.4.7.4)
==12543==    by 0x5CF0721: KJob::result(KJob*) (in /usr/lib/libkdecore.so.5.7.0)
==12543==    by 0x5CF075F: KJob::emitResult() (in /usr/lib/libkdecore.so.5.7.0)
==12543==    by 0x4F6164C: Akonadi::Job::qt_metacall(QMetaObject::Call, int, void**) (in /usr/lib/libakonadi-kde.so.4.7.0)
==12543==    by 0x4EDDCF4: Akonadi::CollectionFetchJob::qt_metacall(QMetaObject::Call, int, void**) (in /usr/lib/libakonadi-kde.so.4.7.0)
==12543==    by 0x562018D: QObject::event(QEvent*) (in /usr/lib/libQtCore.so.4.7.4)
==12543==    by 0x71E9AE3: QApplicationPrivate::notify_helper(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.7.4)
==12543== 
==12543== Invalid read of size 8
==12543==    at 0x4EA3F44: ??? (in /usr/lib/libakonadi-kde.so.4.7.0)
==12543==    by 0x4EA3FFD: Akonadi::Entity::operator=(Akonadi::Entity const&) (in /usr/lib/libakonadi-kde.so.4.7.0)
==12543==    by 0x4168B8: ??? (in /usr/bin/akonadi_maildispatcher_agent)
==12543==    by 0x4169C4: ??? (in /usr/bin/akonadi_maildispatcher_agent)
==12543==    by 0x561C5E9: QMetaObject::activate(QObject*, QMetaObject const*, int, void**) (in /usr/lib/libQtCore.so.4.7.4)
==12543==    by 0x5CF0721: KJob::result(KJob*) (in /usr/lib/libkdecore.so.5.7.0)
==12543==    by 0x5CF075F: KJob::emitResult() (in /usr/lib/libkdecore.so.5.7.0)
==12543==    by 0x4F6164C: Akonadi::Job::qt_metacall(QMetaObject::Call, int, void**) (in /usr/lib/libakonadi-kde.so.4.7.0)
==12543==    by 0x4EDDCF4: Akonadi::CollectionFetchJob::qt_metacall(QMetaObject::Call, int, void**) (in /usr/lib/libakonadi-kde.so.4.7.0)
==12543==    by 0x562018D: QObject::event(QEvent*) (in /usr/lib/libQtCore.so.4.7.4)
==12543==    by 0x71E9AE3: QApplicationPrivate::notify_helper(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.7.4)
==12543==    by 0x71EE950: QApplication::notify(QObject*, QEvent*) (in /usr/lib/libQtGui.so.4.7.4)
==12543==  Address 0x2020203230303231 is not stack'd, malloc'd or (recently) free'd
==12543== 
KCrash: Application 'akonadi_maildispatcher_agent' crashing...
Comment 2 Carl-Erwin Griffith 2011-11-03 12:41:41 UTC
Created attachment 65191 [details]
New crash information added by DrKonqi

akonadi_maildispatcher_agent (4.7) on KDE Platform 4.7.2 (4.7.2) using Qt 4.7.4

- What I was doing when the application crashed:

I was trying to send email, agent segfaults for 3 times. (like previous bug report)

-- Backtrace (Reduced):
#7  operator[] (akey=..., this=0x80) at /usr/include/QtCore/qhash.h:738
#8  KIO::ProtoQueue::removeJob (this=0x0, job=<optimized out>) at /chakra/desktop-testing/kdelibs/src/kdelibs-4.7.2/kio/kio/scheduler.cpp:483
#9  0x00007f1fa3a5ce37 in KIO::SchedulerPrivate::assignJobToSlave (this=<optimized out>, slave=0x20e95e0, job=0x1f7a360) at /chakra/desktop-testing/kdelibs/src/kdelibs-4.7.2/kio/kio/scheduler.cpp:1274
#10 0x00007f1fa632b16c in MailTransport::SmtpJob::startSmtpJob (this=0x1fab3b0) at /chakra/desktop-testing/kdepimlibs/src/kdepimlibs-4.7.2/mailtransport/smtpjob.cpp:239
#11 0x00007f1fa632be52 in MailTransport::SmtpJob::doStart (this=0x1fab3b0) at /chakra/desktop-testing/kdepimlibs/src/kdepimlibs-4.7.2/mailtransport/smtpjob.cpp:129
Comment 3 Allen Winter 2011-11-17 22:28:34 UTC
I fixed this one in the meantime.
Comment 4 Christophe Marin 2011-11-17 22:47:37 UTC
*** Bug 284850 has been marked as a duplicate of this bug. ***
Comment 5 Christophe Marin 2011-11-17 22:47:48 UTC
*** Bug 284847 has been marked as a duplicate of this bug. ***
Comment 6 Christophe Marin 2011-11-17 22:47:56 UTC
*** Bug 283896 has been marked as a duplicate of this bug. ***
Comment 7 Bernhard Jungk 2012-01-18 11:03:39 UTC
I experienced this bug (almost the same backtrace) with the recent version from KDE SC 4.8 RC2. Has the fix been applied to the 4.8 branch?
Comment 8 Christophe Marin 2012-02-06 21:11:36 UTC
*** Bug 292017 has been marked as a duplicate of this bug. ***
Comment 9 Christophe Marin 2012-02-06 21:12:01 UTC
reopen due to bug 292017
Comment 10 ultrabla 2012-02-07 17:35:16 UTC
strange behaviour.

kmail2 stopped receiving mail, i restarted akonadi, suddenly the mail was sent °_°

(4.8.00)
(k)ubuntu with backport ppa...
Comment 11 Bernhard Jungk 2012-02-17 18:37:13 UTC
Created attachment 68882 [details]
New crash information added by DrKonqi

akonadi_maildispatcher_agent (4.8) on KDE Platform 4.8.00 (4.8.0 using Qt 4.7.4

- What I was doing when the application crashed:

Sending a mail, while a proxy server was configured (via autoconfiguration).

-- Backtrace (Reduced):
#7  operator[] (akey=..., this=0x80) at /usr/include/qt4/QtCore/qhash.h:738
#8  KIO::ProtoQueue::removeJob (this=0x0, job=<optimized out>) at ../../kio/kio/scheduler.cpp:483
#9  0x00007fe918455e57 in KIO::SchedulerPrivate::assignJobToSlave (this=<optimized out>, slave=0x2235220, job=0x2243e80) at ../../kio/kio/scheduler.cpp:1274
#10 0x00007fe91ad5e18c in MailTransport::SmtpJob::startSmtpJob (this=0x21d6bb0) at ../../mailtransport/smtpjob.cpp:244
#11 0x00007fe91ad5f0e7 in MailTransport::SmtpJob::doStart (this=0x21d6bb0) at ../../mailtransport/smtpjob.cpp:133
Comment 12 Pino Toscano 2012-03-09 12:52:51 UTC

*** This bug has been marked as a duplicate of bug 282889 ***