Bug 1179442, imap maildir folder has unrepairable incorrect unread count, r=mkmelin, a=rkent
authorR Kent James <rkent@caspia.com>
Mon, 07 Sep 2015 16:50:16 -0700
changeset 26356 b378d2df070c803b0909466673e86980591c7ed2
parent 26355 addd9fa53b40010d10cf47615fda7c99f5d5a4d5
child 26357 b18de0981b18eaa422c8fb4d2eb0e189c329cce4
push id1850
push userclokep@gmail.com
push dateWed, 08 Mar 2017 19:29:12 +0000
treeherdercomm-esr52@028df196b2d9 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmkmelin, rkent
bugs1179442
Bug 1179442, imap maildir folder has unrepairable incorrect unread count, r=mkmelin, a=rkent
mail/base/content/folderPane.js
--- a/mail/base/content/folderPane.js
+++ b/mail/base/content/folderPane.js
@@ -2410,18 +2410,20 @@ let gFolderTreeController = {
       //  lexically captured and available to us.
       if (folder.locked) {
         folder.throwAlertMsg("operationFailedFolderBusy", msgWindow);
         return;
       }
       if (folder.supportsOffline) {
         // Remove the offline store, if any.
         let offlineStore = folder.filePath;
+        // XXX todo: figure out how to delete a maildir directory async. This
+        // delete causes main thread lockup for large maildir folders.
         if (offlineStore.exists())
-          offlineStore.remove(false);
+          offlineStore.remove(true);
       }
       gFolderDisplay.view.close();
 
       // Send a notification that we are triggering a database rebuild.
       MailServices.mfn.notifyItemEvent(folder, "FolderReindexTriggered", null);
 
       folder.msgDatabase.summaryValid = false;