Bug 289831 - Kontact crash after closing kontact with crashed korganizer
Summary: Kontact crash after closing kontact with crashed korganizer
Status: RESOLVED FIXED
Alias: None
Product: kontact
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: openSUSE Linux
: NOR crash
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
: 289855 290080 290083 290162 290617 (view as bug list)
Depends on:
Blocks:
 
Reported: 2011-12-26 08:30 UTC by Johann-Nikolaus Andreae
Modified: 2012-03-18 21:54 UTC (History)
9 users (show)

See Also:
Latest Commit:
Version Fixed In: 4.8.0


Attachments
New crash information added by DrKonqi (10.47 KB, text/plain)
2011-12-28 04:23 UTC, Bernhard Jungk
Details
New crash information added by DrKonqi (10.12 KB, text/plain)
2011-12-28 18:31 UTC, Jessie A. Morris
Details
New crash information added by DrKonqi (11.78 KB, text/plain)
2012-03-18 21:43 UTC, Bruno Friedmann
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Johann-Nikolaus Andreae 2011-12-26 08:30:32 UTC
Application: kontact (4.8 rc1)
KDE Platform Version: 4.7.95 (4.8 RC1 (4.7.95) "release 3"
Qt Version: 4.8.0
Operating System: Linux 3.1.0-1.2-desktop x86_64
Distribution: "openSUSE 12.1 (x86_64)"

-- Information about the crash:
- What I was doing when the application crashed:
Korganizer was crashed (Bug 289830).
Kontact still running.
To use korganizer in kontact closing kontact for restart.
kontact crash.

-- Backtrace:
Application: Kontact (kontact), signal: Aborted
[Current thread is 1 (Thread 0x7ffdbe8a1760 (LWP 5501))]

Thread 3 (Thread 0x7ffda62ea700 (LWP 5503)):
#0  0x00007ffdb66a2e6c in pthread_cond_wait@@GLIBC_2.3.2 () from /lib64/libpthread.so.0
#1  0x00007ffdbb0c8c12 in WTF::TCMalloc_PageHeap::scavengerThread (this=0x7ffdbba671a0) at ../../../Source/JavaScriptCore/wtf/FastMalloc.cpp:2495
#2  0x00007ffdbb0c8c49 in WTF::TCMalloc_PageHeap::runScavengerThread (context=<optimized out>) at ../../../Source/JavaScriptCore/wtf/FastMalloc.cpp:1618
#3  0x00007ffdb669ef05 in start_thread () from /lib64/libpthread.so.0
#4  0x00007ffdbbdb853d in clone () from /lib64/libc.so.6

Thread 2 (Thread 0x7ffda59d1700 (LWP 5504)):
#0  0x00007ffdbbdaf423 in poll () from /lib64/libc.so.6
#1  0x00007ffdb618fa98 in ?? () from /usr/lib64/libglib-2.0.so.0
#2  0x00007ffdb618ff59 in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#3  0x00007ffdbc526946 in QEventDispatcherGlib::processEvents (this=0x7727b0, flags=<optimized out>) at kernel/qeventdispatcher_glib.cpp:426
#4  0x00007ffdbc4f6672 in QEventLoop::processEvents (this=<optimized out>, flags=...) at kernel/qeventloop.cpp:149
#5  0x00007ffdbc4f68c7 in QEventLoop::exec (this=0x7ffda59d0e20, flags=...) at kernel/qeventloop.cpp:204
#6  0x00007ffdbc3f7537 in QThread::exec (this=<optimized out>) at thread/qthread.cpp:501
#7  0x00007ffdbc3fa55b in QThreadPrivate::start (arg=0x771dc0) at thread/qthread_unix.cpp:298
#8  0x00007ffdb669ef05 in start_thread () from /lib64/libpthread.so.0
#9  0x00007ffdbbdb853d in clone () from /lib64/libc.so.6

Thread 1 (Thread 0x7ffdbe8a1760 (LWP 5501)):
[KCrash Handler]
#6  0x00007ffdbbd13d95 in raise () from /lib64/libc.so.6
#7  0x00007ffdbbd152ab in abort () from /lib64/libc.so.6
#8  0x00007ffdbbd4dece in __libc_message () from /lib64/libc.so.6
#9  0x00007ffdbbd53c06 in malloc_printerr () from /lib64/libc.so.6
#10 0x00007ffdb8b72ded in qDeleteAll<QList<Node*>::const_iterator> (end=<optimized out>, begin=<optimized out>) at /usr/include/QtCore/qalgorithms.h:322
#11 qDeleteAll<QList<Node*> > (c=...) at /usr/include/QtCore/qalgorithms.h:330
#12 Akonadi::EntityTreeModel::~EntityTreeModel (this=0xce6ee0, __in_chrg=<optimized out>) at /usr/src/debug/kdepimlibs-4.7.95/akonadi/entitytreemodel.cpp:79
#13 0x00007ffdb8b72e79 in Akonadi::EntityTreeModel::~EntityTreeModel (this=0xce6ee0, __in_chrg=<optimized out>) at /usr/src/debug/kdepimlibs-4.7.95/akonadi/entitytreemodel.cpp:83
#14 0x00007ffdbc509e05 in QObjectPrivate::deleteChildren (this=0xc46c40) at kernel/qobject.cpp:1917
#15 0x00007ffdbc51006c in QObject::~QObject (this=0xc85820, __in_chrg=<optimized out>) at kernel/qobject.cpp:927
#16 0x00007ffd60f765ed in KMKernel::~KMKernel (this=0xc85820, __in_chrg=<optimized out>) at /usr/src/debug/kdepim-4.7.95/kmail/kmkernel.cpp:226
#17 0x00007ffd60f76759 in KMKernel::~KMKernel (this=0xc85820, __in_chrg=<optimized out>) at /usr/src/debug/kdepim-4.7.95/kmail/kmkernel.cpp:236
#18 0x00007ffd612dbd45 in KMailPart::~KMailPart (this=0x8e13b0, __in_chrg=<optimized out>, __vtt_parm=<optimized out>) at /usr/src/debug/kdepim-4.7.95/kmail/kmail_part.cpp:138
#19 0x00007ffd612dbe39 in KMailPart::~KMailPart (this=0x8e13b0, __in_chrg=<optimized out>, __vtt_parm=<optimized out>) at /usr/src/debug/kdepim-4.7.95/kmail/kmail_part.cpp:140
#20 0x00007ffdbe09420e in KontactInterface::Plugin::~Plugin (this=0xa660f0, __vtt_parm=<optimized out>, __in_chrg=<optimized out>) at /usr/src/debug/kdepimlibs-4.7.95/kontactinterface/plugin.cpp:90
#21 0x00007ffd621734ef in KMailPlugin::~KMailPlugin (this=0xa660f0, __in_chrg=<optimized out>, __vtt_parm=<optimized out>) at /usr/src/debug/kdepim-4.7.95/kontact/plugins/kmail/kmail_plugin.cpp:159
#22 0x00007ffd62173519 in KMailPlugin::~KMailPlugin (this=0xa660f0, __in_chrg=<optimized out>, __vtt_parm=<optimized out>) at /usr/src/debug/kdepim-4.7.95/kontact/plugins/kmail/kmail_plugin.cpp:163
#23 0x00007ffdbe4cc107 in Kontact::MainWindow::~MainWindow (this=0x76cda0, __in_chrg=<optimized out>, __vtt_parm=<optimized out>) at /usr/src/debug/kdepim-4.7.95/kontact/src/mainwindow.cpp:288
#24 0x00007ffdbe4cc269 in Kontact::MainWindow::~MainWindow (this=0x76cda0, __in_chrg=<optimized out>, __vtt_parm=<optimized out>) at /usr/src/debug/kdepim-4.7.95/kontact/src/mainwindow.cpp:290
#25 0x00007ffdbc510948 in QObject::event (this=0x76cda0, e=<optimized out>) at kernel/qobject.cpp:1185
#26 0x00007ffdbcf5afcb in QWidget::event (this=0x76cda0, event=0x680dea0) at kernel/qwidget.cpp:8820
#27 0x00007ffdbd3310db in QMainWindow::event (this=0x76cda0, event=0x680dea0) at widgets/qmainwindow.cpp:1478
#28 0x00007ffdbdd497b8 in KXmlGuiWindow::event (this=0x76cda0, ev=0x680dea0) at /usr/src/debug/kdelibs-4.7.95/kdeui/xmlgui/kxmlguiwindow.cpp:126
#29 0x00007ffdbcf0ae84 in notify_helper (e=0x680dea0, receiver=0x76cda0, this=0x63aa30) at kernel/qapplication.cpp:4550
#30 QApplicationPrivate::notify_helper (this=0x63aa30, receiver=0x76cda0, e=0x680dea0) at kernel/qapplication.cpp:4522
#31 0x00007ffdbcf0fd03 in QApplication::notify (this=0x7fffa0e31bc0, receiver=0x76cda0, e=0x680dea0) at kernel/qapplication.cpp:4411
#32 0x00007ffdbdc4e6f6 in KApplication::notify (this=0x7fffa0e31bc0, receiver=0x76cda0, event=0x680dea0) at /usr/src/debug/kdelibs-4.7.95/kdeui/kernel/kapplication.cpp:311
#33 0x00007ffdbc4f788c in QCoreApplication::notifyInternal (this=0x7fffa0e31bc0, receiver=0x76cda0, event=0x680dea0) at kernel/qcoreapplication.cpp:876
#34 0x00007ffdbc4fb12a in sendEvent (event=0x680dea0, receiver=0x76cda0) at kernel/qcoreapplication.h:231
#35 QCoreApplicationPrivate::sendPostedEvents (receiver=0x0, event_type=0, data=0x60df50) at kernel/qcoreapplication.cpp:1500
#36 0x00007ffdbc5264b3 in sendPostedEvents () at kernel/qcoreapplication.h:236
#37 postEventSourceDispatch (s=<optimized out>) at kernel/qeventdispatcher_glib.cpp:279
#38 0x00007ffdb618f58d in g_main_context_dispatch () from /usr/lib64/libglib-2.0.so.0
#39 0x00007ffdb618fd88 in ?? () from /usr/lib64/libglib-2.0.so.0
#40 0x00007ffdb618ff59 in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0
#41 0x00007ffdbc5268df in QEventDispatcherGlib::processEvents (this=0x60d7e0, flags=<optimized out>) at kernel/qeventdispatcher_glib.cpp:424
#42 0x00007ffdbcfae2de in QGuiEventDispatcherGlib::processEvents (this=<optimized out>, flags=<optimized out>) at kernel/qguieventdispatcher_glib.cpp:204
#43 0x00007ffdbc4f6672 in QEventLoop::processEvents (this=<optimized out>, flags=...) at kernel/qeventloop.cpp:149
#44 0x00007ffdbc4f68c7 in QEventLoop::exec (this=0x7fffa0e31b50, flags=...) at kernel/qeventloop.cpp:204
#45 0x00007ffdbc4fb425 in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1148
#46 0x0000000000403919 in main (argc=1, argv=0x7fffa0e321e8) at /usr/src/debug/kdepim-4.7.95/kontact/src/main.cpp:218

Reported using DrKonqi
Comment 1 Christophe Marin 2011-12-27 12:04:27 UTC
*** Bug 289855 has been marked as a duplicate of this bug. ***
Comment 2 Bernhard Jungk 2011-12-28 04:23:30 UTC
Created attachment 67175 [details]
New crash information added by DrKonqi

kontact (4.8 rc1) on KDE Platform 4.7.95 (4.8 RC1 (4.7.95) using Qt 4.7.4

- What I was doing when the application crashed:

I tried to move a message from one folder back to the inbox to try a new filter. What actually happend was not what I expected:

1. I moved the message via drag and drop to the inbox
2. The message disappeared in the originating folder
3. Switching to the inbox showed no sign of the message
4. Switching back to the originating folder showed the message sitting there
5. Quitting Kontact/KMail2 now crashes Kontact/KMail2

Notice that Kontact/KMail2 does not crash if moving a message succeeded, which sometimes does work. It seems to work for some folders and not for others.

-- Backtrace (Reduced):
#6  0x00007f778ad7f3a5 in __GI_raise (sig=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:64
#7  0x00007f778ad82b0b in __GI_abort () at abort.c:92
[...]
#9  0x00007f778adc1a96 in malloc_printerr (action=3, str=0x7f778aea8108 "munmap_chunk(): invalid pointer", ptr=<optimized out>) at malloc.c:6283
#10 0x00007f7787be496d in qDeleteAll<QList<Node*>::const_iterator> (end=<optimized out>, begin=<optimized out>) at /usr/include/qt4/QtCore/qalgorithms.h:322
#11 qDeleteAll<QList<Node*> > (c=...) at /usr/include/qt4/QtCore/qalgorithms.h:330
Comment 3 Bernhard Jungk 2011-12-28 04:27:40 UTC
> 1. I moved the message via drag and drop to the inbox
> 2. The message disappeared in the originating folder
> 3. Switching to the inbox showed no sign of the message
> 4. Switching back to the originating folder showed the message sitting there
> 5. Quitting Kontact/KMail2 now crashes Kontact/KMail2

Actually I got this description wrong. (4) is does not show any message in the originating folder!
Comment 4 Jessie A. Morris 2011-12-28 18:31:34 UTC
Created attachment 67197 [details]
New crash information added by DrKonqi

kontact (4.8 rc1) on KDE Platform 4.7.95 (4.8 RC1 (4.7.95) using Qt 4.7.4

- What I was doing when the application crashed:

I quit Kontact and I got the 'This application has crashed.

-- Backtrace (Reduced):
#6  0x00007f1443c0b3a5 in __GI_raise (sig=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:64
#7  0x00007f1443c0eb0b in __GI_abort () at abort.c:92
[...]
#9  0x00007f1443c4da96 in malloc_printerr (action=3, str=0x7f1443d34278 "double free or corruption (!prev)", ptr=<optimized out>) at malloc.c:6283
#10 0x00007f1443c51d7c in __GI___libc_free (mem=<optimized out>) at malloc.c:3738
#11 0x00007f1440a7096d in qDeleteAll<QList<Node*>::const_iterator> (end=<optimized out>, begin=<optimized out>) at /usr/include/qt4/QtCore/qalgorithms.h:322
Comment 5 Allen Winter 2011-12-28 20:21:49 UTC
Git commit 43b7d9886797bcf06019e9521455e534d07fd6b5 by Allen Winter.
Committed on 28/12/2011 at 21:19.
Pushed by winterz into branch 'master'.

try to safely delete all the Node pointers from each child entity list
instead of using qDeleteAll(), whose behavior has changed in Qt4.8.

MERGE: 4.8
FIXED-IN: 4.8.0

M  +6    -3    akonadi/entitytreemodel.cpp

http://commits.kde.org/kdepimlibs/43b7d9886797bcf06019e9521455e534d07fd6b5
Comment 6 Allen Winter 2011-12-28 20:23:02 UTC
Git commit 83ee910e6131061359ec288c5bdbb6da944cc97a by Allen Winter.
Committed on 28/12/2011 at 21:19.
Pushed by winterz into branch 'KDE/4.8'.

try to safely delete all the Node pointers from each child entity list
instead of using qDeleteAll(), whose behavior has changed in Qt4.8.

MERGE: 4.8
FIXED-IN: 4.8.0
(cherry picked from commit 43b7d9886797bcf06019e9521455e534d07fd6b5)

M  +6    -3    akonadi/entitytreemodel.cpp

http://commits.kde.org/kdepimlibs/83ee910e6131061359ec288c5bdbb6da944cc97a
Comment 7 Christophe Marin 2011-12-30 10:22:54 UTC
*** Bug 290083 has been marked as a duplicate of this bug. ***
Comment 8 Christophe Marin 2012-01-02 17:37:27 UTC
*** Bug 290162 has been marked as a duplicate of this bug. ***
Comment 9 Christophe Marin 2012-01-04 13:18:49 UTC
Allen, can you have a look at https://bugs.kde.org/show_bug.cgi?id=289693#c21

which happens after your two commits for the qdeleteall crash (https://bugs.kde.org/show_bug.cgi?id=289693#c11 for the details)
Comment 10 Allen Winter 2012-01-05 00:55:58 UTC
I did, but unfortunately try as I might I just cannot make this happen.  So all I can do is make some educated guesses.

does anyone want to try a patch?
Comment 11 Christophe Marin 2012-01-05 11:07:48 UTC
maybe post it to 289693. I can't specifically reproduce the crash (I can reproduce one in kontact but I don't think it's related)
Comment 12 Colin J Thomson 2012-01-05 22:49:29 UTC
Looks fixed here after the rc2 update Fedora 16, thanks..
Comment 13 Christophe Marin 2012-01-06 17:41:59 UTC
*** Bug 290080 has been marked as a duplicate of this bug. ***
Comment 14 Christophe Marin 2012-01-09 16:34:18 UTC
*** Bug 290617 has been marked as a duplicate of this bug. ***
Comment 15 Bruno Friedmann 2012-03-18 21:43:22 UTC
Created attachment 69720 [details]
New crash information added by DrKonqi

kontact (4.8.0) on KDE Platform 4.8.1 (4.8.1) "release 481" using Qt 4.8.0

- What I was doing when the application crashed: Playing with my mails during the whole day. Then when I ask to quit, there's a message in tray telling that akonadi has loose connection with the imap folder on which I was during the quit.

Then kontact crash.
Seems not fixed in 4.8.1 unfortunately !

-- Backtrace (Reduced):
#7  ~QString (this=0xe1da040, __in_chrg=<optimized out>) at /usr/include/QtCore/qstring.h:880
#8  ~AddrSpec (this=0xe1da038, __in_chrg=<optimized out>) at /usr/src/debug/kdepimlibs-4.8.1/kmime/kmime_header_parsing.h:54
#9  ~Mailbox (this=0xe1da030, __in_chrg=<optimized out>) at /usr/src/debug/kdepimlibs-4.8.1/kmime/kmime_header_parsing.h:68
#10 node_destruct (to=0xe1da018, from=0xe1da018, this=<optimized out>) at /usr/include/QtCore/qlist.h:431
#11 QList<KMime::Types::Mailbox>::free (data=0xe1da000, this=<optimized out>) at /usr/include/QtCore/qlist.h:757