Bug 174244 - Kontact crashes regularly on exit
Summary: Kontact crashes regularly on exit
Status: RESOLVED FIXED
Alias: None
Product: korganizer
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Mandriva RPMs Linux
: NOR crash
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
: 181728 186006 190578 196115 197408 199825 204215 209114 (view as bug list)
Depends on:
Blocks:
 
Reported: 2008-11-04 13:37 UTC by Anatoli Strigin
Modified: 2009-10-01 19:02 UTC (History)
14 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
valgrind report (22.47 KB, text/plain)
2009-09-11 14:29 UTC, Sebastian Held
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Anatoli Strigin 2008-11-04 13:37:10 UTC
Version:            (using KDE 4.1.2)
Compiler:          gcc (GCC) 4.3.2 
OS:                Linux
Installed from:    Mandriva RPMs

I use Mandriva 2009.1 on an external USB drive. I installed some parts of KDE 3.5.10 in order to be able to run taskjuggler, but use KDE 4.1.2.  Presumably this is not a bug, but some property of my system. But this strange behaviour may indicate a bug. 
So:

Kontact crashes on exit irrespective of which applcation is opened, though the applications seem to exit OK, if started separately.

Here are the two latest krash-traces:
The first:
...
(no debugging symbols found)
[KCrash handler]
#6  0xb5a80a90 in KCal::Incidence::removeRelation ()
   from /usr/lib/libkcal.so.4
#7  0xb5a83312 in KCal::Incidence::~Incidence () from /usr/lib/libkcal.so.4
#8  0xb5a86f67 in KCal::Todo::~Todo () from /usr/lib/libkcal.so.4
#9  0xb5aab586 in KCal::CalendarLocal::close () from /usr/lib/libkcal.so.4
#10 0xb5af1563 in KCal::ResourceCached::doClose () from /usr/lib/libkcal.so.4
#11 0xb5beb0b8 in KRES::Resource::close () from /usr/lib/libkresources.so.4
#12 0xb5afa11b in KCal::CalendarResources::close () from /usr/lib/libkcal.so.4
#13 0xb5afa483 in KCal::CalendarResources::~CalendarResources ()
   from /usr/lib/libkcal.so.4
#14 0xb1bcc8d4 in KOrg::StdCalendar::~StdCalendar ()
   from /usr/lib/libkorganizer_calendar.so.4
#15 0xb1bcd9cf in ?? () from /usr/lib/libkorganizer_calendar.so.4
#16 0xb590e5a3 in ?? () from /usr/lib/libkde3support.so.4
#17 0xb76dde05 in qt_call_post_routines () from /usr/lib/libQtCore.so.4
#18 0xb6d9b73a in QApplication::~QApplication () from /usr/lib/libQtGui.so.4
#19 0xb7ba64f8 in KApplication::~KApplication () from /usr/lib/libkdeui.so.5
#20 0xb7bad2c8 in KUniqueApplication::~KUniqueApplication ()
   from /usr/lib/libkdeui.so.5
#21 0x0804bb9b in _start ()

The second:
[KCrash handler]
#6  0xb5b91a90 in KCal::Incidence::removeRelation ()
   from /usr/lib/libkcal.so.4
#7  0xb5b94312 in KCal::Incidence::~Incidence () from /usr/lib/libkcal.so.4
#8  0xb5b97f67 in KCal::Todo::~Todo () from /usr/lib/libkcal.so.4
#9  0xb5bbc586 in KCal::CalendarLocal::close () from /usr/lib/libkcal.so.4
#10 0xb5c02563 in KCal::ResourceCached::doClose () from /usr/lib/libkcal.so.4
#11 0xb5cfc0b8 in KRES::Resource::close () from /usr/lib/libkresources.so.4
#12 0xb5c0b11b in KCal::CalendarResources::close () from /usr/lib/libkcal.so.4
#13 0xb5c0b483 in KCal::CalendarResources::~CalendarResources ()
   from /usr/lib/libkcal.so.4
#14 0xb1cdd8d4 in KOrg::StdCalendar::~StdCalendar ()
   from /usr/lib/libkorganizer_calendar.so.4
#15 0xb1cde9cf in ?? () from /usr/lib/libkorganizer_calendar.so.4
#16 0xb5a1f5a3 in ?? () from /usr/lib/libkde3support.so.4
#17 0xb77eee05 in qt_call_post_routines () from /usr/lib/libQtCore.so.4
#18 0xb6eac73a in QApplication::~QApplication () from /usr/lib/libQtGui.so.4
#19 0xb7cb74f8 in KApplication::~KApplication () from /usr/lib/libkdeui.so.5
#20 0xb7cbe2c8 in KUniqueApplication::~KUniqueApplication ()
   from /usr/lib/libkdeui.so.5
#21 0x0804bb9b in _start ()
Comment 1 Allen Winter 2008-11-04 14:20:38 UTC
A fix for the crash in KCal::Incidence::removeRelation() was made a few days ago and will appear in KDE 4.1.3 and KDE 4.2.0.
Comment 2 Peter Soetens 2009-02-04 22:43:20 UTC
I still have this exact same crash with using KDE 4.1.4 on Ubuntu Intrepid. I guess I'll submit this on Launchpad then...

0x00007f82ff4495f0 in nanosleep () from /lib/libc.so.6

Thread 1 (Thread 0x7f8301d796f0 (LWP 3736)):
[KCrash Handler]
#5  0x00007f82fcc41029 in KCal::Incidence::removeRelation () from /usr/lib/libkcal.so.4
#6  0x00007f82fcc44567 in KCal::Incidence::~Incidence () from /usr/lib/libkcal.so.4
#7  0x00007f82fcc46445 in KCal::Todo::~Todo () from /usr/lib/libkcal.so.4
#8  0x00007f82fcc6d62e in KCal::CalendarLocal::close () from /usr/lib/libkcal.so.4
#9  0x00007f82fd1cc756 in KRES::Resource::close () from /usr/lib/libkresources.so.4
#10 0x00007f82fccc0339 in KCal::CalendarResources::close () from /usr/lib/libkcal.so.4
#11 0x00007f82fccc06ad in KCal::CalendarResources::~CalendarResources () from /usr/lib/libkcal.so.4
#12 0x00007f82ecb34dd6 in KOrg::StdCalendar::~StdCalendar () from /usr/lib/libkorganizer_calendar.so.4
#13 0x00007f82ecb36477 in ?? () from /usr/lib/libkorganizer_calendar.so.4
#14 0x00007f82fc299559 in ?? () from /usr/lib/libkde3support.so.4
#15 0x00007f83006c9315 in qt_call_post_routines () from /usr/lib/libQtCore.so.4
#16 0x00007f82ffbf4388 in QApplication::~QApplication () from /usr/lib/libQtGui.so.4
#17 0x0000000000404971 in _start ()
Comment 3 Sergio Martins 2009-03-03 01:34:02 UTC
*** Bug 181728 has been marked as a duplicate of this bug. ***
Comment 4 Sergio Martins 2009-03-03 01:52:04 UTC
*** Bug 186006 has been marked as a duplicate of this bug. ***
Comment 5 Sergio Martins 2009-03-03 02:03:28 UTC
I'm reopening this one since reporter still reproduces this in KDE4.1.4 and another reporter reproduces this with KDE4.2.

Are you using an akonadi resource?

Does it still crashes? If so, can you get a valgrind report?

1. Install valgrind
2. Run: valgrind kontact --nofork &> report.txt
3. make kontact crash
4. attach report.txt here

Thanks
Comment 6 Sergio Martins 2009-03-03 04:33:22 UTC
Comments which Ricardo sent to my e-mail.

> Did it crashed while closing?
>  -Yes, Kontact crash while closing-
> Are you using an akonadi resource?
>  -Yes, I do.
> Can you reproduce this?
>  -Yes, I can. Every time when i close the app.
> Are you really using KDE4.2?
>  -Yes, I'm using KDE4.2

Ricardo, the valgrind report you sent me doesn't have any debug symbols, can you read: http://techbase.kde.org/Development/Tutorials/Debugging/How_to_create_useful_crash_reports

and then run valgrind again

Thanks
Comment 7 Dario Andres 2009-04-26 15:35:55 UTC
*** Bug 190578 has been marked as a duplicate of this bug. ***
Comment 8 czikus 2009-05-10 12:43:57 UTC
I would like to confirm this bug. Kontact crashes always on exit with exactly the same backtrace. I've noticed that it happens only when the summary page in kontact is enabled. If only korganizer is used and not the summary page, kontact closes successfully.
Comment 9 Dario Andres 2009-06-12 01:44:52 UTC
*** Bug 196115 has been marked as a duplicate of this bug. ***
Comment 10 Dario Andres 2009-06-12 01:45:22 UTC
Bug 196115 has a complete backtrace from 4.2.90
Comment 11 Dario Andres 2009-06-21 21:57:29 UTC
*** Bug 197408 has been marked as a duplicate of this bug. ***
Comment 12 Christophe Marin 2009-07-12 17:03:21 UTC
*** Bug 199825 has been marked as a duplicate of this bug. ***
Comment 13 Christophe Marin 2009-08-18 00:48:18 UTC
*** Bug 204215 has been marked as a duplicate of this bug. ***
Comment 14 Sebastian Held 2009-09-11 14:29:53 UTC
Created attachment 36868 [details]
valgrind report

This is kde-4.3.1

Here is the corresponding backtrace:
gdb korganizer
GNU gdb 6.8
Copyright (C) 2008 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-pc-linux-gnu"...
(gdb) set args --nocrashhandler --nofork
(gdb) run
Starting program: /usr/bin/korganizer --nocrashhandler --nofork
[Thread debugging using libthread_db enabled]
[New Thread 0x7f1406d86750 (LWP 28493)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7f1406d86750 (LWP 28493)]
KCal::Incidence::removeRelation (this=0x11c92c0, incidence=0xf2c100) at /usr/include/qt4/QtCore/qlist.h:664
664         Node *b = reinterpret_cast<Node *>(p.begin());
(gdb) bt full
#0  KCal::Incidence::removeRelation (this=0x11c92c0, incidence=0xf2c100) at /usr/include/qt4/QtCore/qlist.h:664
No locals.
#1  0x00007f1405e9d3ae in ~Incidence (this=0xf2c100) at /var/tmp/portage/kde-base/kdepimlibs-4.3.1/work/kdepimlibs-4.3.1/kcal/incidence.cpp:206
        relations = {<QList<KCal::Incidence*>> = {{p = {static shared_null = {ref = {_q_value = 3877}, alloc = 0, begin = 0, end = 0, sharable = 1, array = {0x0}}, d = 0x60da50}, d = 0x60da50}}, mAutoDelete = false}
#2  0x00007f1405e9eead in ~Todo (this=0xf2c100) at /var/tmp/portage/kde-base/kdepimlibs-4.3.1/work/kdepimlibs-4.3.1/kcal/todo.cpp:103
No locals.
#3  0x00007f1405eb8943 in KCal::CalendarLocal::close (this=0xa806c0) at /usr/include/qt4/QtCore/qalgorithms.h:350
No locals.
#4  0x00007f1403f5c719 in KRES::Resource::close (this=0xa926f0) at /var/tmp/portage/kde-base/kdepimlibs-4.3.1/work/kdepimlibs-4.3.1/kresources/resource.cpp:141
        __PRETTY_FUNCTION__ = "void KRES::Resource::close()"
#5  0x00007f1405eea2b5 in KCal::CalendarResources::close (this=0xa1c200) at /var/tmp/portage/kde-base/kdepimlibs-4.3.1/work/kdepimlibs-4.3.1/kcal/calendarresources.cpp:350
        it = {mIt = {i = 0xab8f08}, mList = 0xa22aa0}
#6  0x00007f1405eea56e in ~CalendarResources (this=0x11c92c0) at /var/tmp/portage/kde-base/kdepimlibs-4.3.1/work/kdepimlibs-4.3.1/kcal/calendarresources.cpp:247
No locals.
#7  0x00007f1405128189 in ~StdCalendar (this=0x11c92c0) at /var/tmp/portage/kde-base/korganizer-4.3.1/work/korganizer-4.3.1/korganizer/stdcalendar.cpp:112
No locals.
#8  0x00007f14051291ef in K3StaticDeleter<KOrg::StdCalendar>::destructObject (this=0x7f140532a1b0) at /usr/include/k3staticdeleter.h:174
No locals.
#9  0x00007f14063d3efd in K3StaticDeleterPrivate::deleteStaticDeleters () from /usr/lib64/libkde3support.so.4
No symbol table info available.
#10 0x00007f1402509b35 in qt_call_post_routines () at kernel/qcoreapplication.cpp:163
        list = (QVFuncList *) 0x637680
#11 0x00007f1401563228 in ~QApplication (this=0x7ffff9702270) at kernel/qapplication.cpp:971
        d = (QApplicationPrivate * const) 0x63f650
#12 0x0000000000408dc5 in main (argc=<value optimized out>, argv=<value optimized out>) at /var/tmp/portage/kde-base/korganizer-4.3.1/work/korganizer-4.3.1/korganizer/main.cpp:61
        aboutData = {<KAboutData> = {d = 0x614540}, <No data fields>}
        app = {<KPIM::PimApplication> = {<> = {<No data fields>}, <No data fields>}, static staticMetaObject = {d = {superdata = 0x60da30, stringdata = 0x40bc80 "KOrganizerApp", data = 0x40bd00, extradata = 0x0}}}
(gdb)
Comment 15 Thomas McGuire 2009-10-01 18:35:23 UTC
*** Bug 209114 has been marked as a duplicate of this bug. ***
Comment 16 Thomas McGuire 2009-10-01 18:36:05 UTC
Remove the relations of deleted incidences.
Please review.

This fixes a crash when quitting Kontact and a crash when running the unit tests.

BUG: 174244
Comment 17 Thomas McGuire 2009-10-01 18:37:50 UTC
Should be fixed with the above commit, which I also backported to the KDE 4.3 branch, so the fix will be in KDE 4.3.2.

BTW, the crash was caused by having nested todos with a special structure.
Comment 18 Nick Elliott 2009-10-01 18:44:18 UTC
Thank you, and yes, I do have nested todos.
Comment 19 Thomas McGuire 2009-10-01 19:02:11 UTC
*** Bug 197408 has been marked as a duplicate of this bug. ***