[Bug 113329] KMail crash on startup

Will Stephenson <[email protected]>
Newsgroups gmane.comp.kde.devel.kmail
Message-ID <[email protected]>
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
         
http://bugs.kde.org/show_bug.cgi?id=113329         




------- Additional Comments From wstephenson kde org  2007-03-20 19:47 -------
SVN commit 644705 by wstephens:

Don't continue checking mail in the other folders when a local folder was removed, it causes a crash on startup.

There is still a bug that local folders are removed erroneously because their ImapPath somehow become empty, but at least they can be recovered with Refresh Folder List now.
CCBUG:113329


 M  +3 -1      kmacctimap.cpp  


--- branches/work/kmail_debug_imap/kmacctimap.cpp #644704:644705
 @ -342,7 +342,7  @
         else {
           connect(imapFolder, SIGNAL(numUnreadMsgsChanged(KMFolder*)),
               this, SLOT(postProcessNewMail(KMFolder*)));
-          bool ok = imapFolder->processNewMail(interactive);
+          bool ok = imapFolder->processNewMail(interactive); // this removes the local kmfolderimap if its imapPath is somehow empty, and removing it calls createFolderList, invalidating mMailCheckFolders, and causing a crash
           if (!ok)
           {
             // there was an error so cancel
 @ -352,6 +352,8  @
               mMailCheckProgressItem->incCompletedItems();
               mMailCheckProgressItem->updateProgress();
             }
+            // since the list of folders might have been updated at this point, mMailCheckFolders may be invalid, so break
+            break;
           }
         }
       }
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.