Bug 142945 - infinite loop/recursion with cachedimap korganizer resource
Summary: infinite loop/recursion with cachedimap korganizer resource
Status: RESOLVED INTENTIONAL
Alias: None
Product: kontact
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Fedora RPMs Linux
: NOR normal
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-03-14 07:32 UTC by Gary Granger
Modified: 2013-06-18 07:20 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
log output for kontact session in which recursion starts (78.51 KB, text/plain)
2007-03-14 07:37 UTC, Gary Granger
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Gary Granger 2007-03-14 07:32:27 UTC
Version:           branches/KDE/3.5/kdepim@640119 (using KDE KDE 3.5.5)
Installed from:    Fedora RPMs
Compiler:          gcc version 4.1.1 20070105 (Red Hat 4.1.1-51) compiling the kdepim 3.5 branch against fedora KDE 3.5.5 RPMs
OS:                Linux

I am using kontact/korganizer with a cachedimap resource for calendar, tasks, jourrnals, and addressbook.  Sometimes kontact goes into an infinite loop and spikes the CPU load, to the point of making the system unusable.  The crux of the problem appears to be these lines in the log messages:

kmail: KMailICalIfaceImpl::update( /home/granger/.kde/share/apps/kmail/dimap/.12
73591563.directory/Tasks, 1107766 )
kmail: ()
kmail: ()
kmail: ()
kmail: deleted attachments:()
kmail: Emitting DCOP signal incidenceDeleted( Task, /home/granger/.kde/share/app
s/kmail/dimap/.1273591563.directory/Tasks, libkcal-2127411314.850 )
kmail: forget about 1107766, it's 1107767 now

The messages continue:

kmail: KMailICalIfaceImpl::update( /home/granger/.kde/share/apps/kmail/dimap/.12
73591563.directory/Tasks, 1107767 )
kmail: ()
kmail: ()
kmail: ()
kmail: deleted attachments:()
kmail: Emitting DCOP signal incidenceDeleted( Task, /home/granger/.kde/share/app
s/kmail/dimap/.1273591563.directory/Tasks, libkcal-2127411314.850 )
kmail: forget about 1107767, it's 1107768 now

It seems like kmail is creating lots of extra entries in the imap cache, except they do not appear to be written to any files under ~/.kde/share/apps/kmail/dimap, since I do not find any large files there.  When restarting kontact, there are repeated console messages about not finding a file for lots of imap entries, presumably the entries created by the recursion.  Refreshing the local imap cache returns things to normal.

I have not figured out what triggers the problem.  It seems to happen even after turning off automatic imap synchronizations, and even if I haven't even provided the password to the imap server yet.  I have modified the source to print some extra backtraces around the code which contains the "forget about..." message, and I will attach a log file.  I have tried to understand the KMailIcalIfaceImpl code, but I'm not grasping it very quickly.  So perhaps someone can point me in the right direction.  Is there some documentation or a particular source file I should look at to get an overview of the interface between KMail Ical and KOrganizer?  Anyone have a clue as to what would cause this kind of recursion?  Thanks.
Comment 1 Gary Granger 2007-03-14 07:37:24 UTC
Created attachment 19968 [details]
log output for kontact session in which recursion starts

This log is a normal startup of kontact, which after being left running for a
while went into an infinite loop.  I truncated the log after the first few
recursions.  Unfortunately I don't remember if I edited the calendar or tasks,
but hopefully the log shows that.
Comment 2 Laurent Montel 2013-06-18 07:20:24 UTC
We can close.
kdepim is in 4.11 now and all code changed.