Remove workaround for bug 522353 from nsPlacesDBFlush component
authorMarco Bonardo <mbonardo@mozilla.com>
Thu, 19 Nov 2009 14:15:08 +0100
changeset 35132 5b631f59dda37357b53326907668cd2cfc5e0901
parent 35131 8fb97bb36e55fefaa56dd4058c8286b15172a701
child 35133 7d8cf8b7c3f98ce90098c05a7415f4bb38ef50e9
push id10427
push usermak77@bonardo.net
push dateThu, 19 Nov 2009 13:16:10 +0000
treeherdermozilla-central@5b631f59dda3 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs522353
milestone1.9.3a1pre
Remove workaround for bug 522353 from nsPlacesDBFlush component
toolkit/components/places/src/nsPlacesDBFlush.js
--- a/toolkit/components/places/src/nsPlacesDBFlush.js
+++ b/toolkit/components/places/src/nsPlacesDBFlush.js
@@ -171,30 +171,16 @@ nsPlacesDBFlush.prototype = {
       let tm = Cc["@mozilla.org/thread-manager;1"].
           getService(Ci.nsIThreadManager);
       tm.mainThread.dispatch({
         _self: this,
         run: function() {
           // Flush any remaining change to disk tables.
           this._self._flushWithQueries([kQuerySyncPlacesId, kQuerySyncHistoryVisitsId]);
 
-          // Ensure we won't act anymore as a category observer, so we stop
-          // being notified.
-          // This should not be needed but due to bug 522353 we leak in tests
-          // if we don't manually remove the entries.
-          // WARNING: These changes must NOT be persistent!
-          let catMan = Cc["@mozilla.org/categorymanager;1"].
-                       getService(Ci.nsICategoryManager);
-          catMan.deleteCategoryEntry("bookmark-observers",
-                                     this._self.classDescription,
-                                     false); // Only for this session!
-          catMan.deleteCategoryEntry("history-observers",
-                                     this._self.classDescription,
-                                     false); // Only for this session!
-
           // Close the database connection, this was the last sync and we can't
           // ensure database coherence from now on.
           this._self._finalizeInternalStatements();
           this._self._db.close();
         }
       }, Ci.nsIThread.DISPATCH_NORMAL);
     }
     else if (aTopic == "nsPref:changed" && aData == kSyncPrefName) {