Bug 1116551 - Remove the code to handle shutdown-cleanse from the prefs service; r=bsmedberg
authorEhsan Akhgari <ehsan@mozilla.com>
Tue, 30 Dec 2014 14:17:35 -0500
changeset 247754 e18f8c0cf429de80c5250f001a8ca84861a8eb70
parent 247753 3e9029d8a6594be89dcb4f89c831e583e2df5802
child 247755 8fcced3ba6d89a9c9f5783a58d302effee4266c3
push id4489
push userraliiev@mozilla.com
push dateMon, 23 Feb 2015 15:17:55 +0000
treeherdermozilla-beta@fd7c3dc24146 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbsmedberg
bugs1116551
milestone37.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1116551 - Remove the code to handle shutdown-cleanse from the prefs service; r=bsmedberg shutdown-cleanse has not been a thing for quite a while.
modules/libpref/Preferences.cpp
--- a/modules/libpref/Preferences.cpp
+++ b/modules/libpref/Preferences.cpp
@@ -582,24 +582,17 @@ Preferences::Observe(nsISupports *aSubje
                      const char16_t *someData)
 {
   if (XRE_GetProcessType() == GeckoProcessType_Content)
     return NS_ERROR_NOT_AVAILABLE;
 
   nsresult rv = NS_OK;
 
   if (!nsCRT::strcmp(aTopic, "profile-before-change")) {
-    if (!nsCRT::strcmp(someData, MOZ_UTF16("shutdown-cleanse"))) {
-      if (mCurrentFile) {
-        mCurrentFile->Remove(false);
-        mCurrentFile = nullptr;
-      }
-    } else {
-      rv = SavePrefFile(nullptr);
-    }
+    rv = SavePrefFile(nullptr);
   } else if (!strcmp(aTopic, "load-extension-defaults")) {
     pref_LoadPrefsInDirList(NS_EXT_PREFS_DEFAULTS_DIR_LIST);
   } else if (!nsCRT::strcmp(aTopic, "reload-default-prefs")) {
     // Reload the default prefs from file.
     pref_InitInitialObjects();
   } else if (!nsCRT::strcmp(aTopic, "suspend_process_notification")) {
     // Our process is being suspended. The OS may wake our process later,
     // or it may kill the process. In case our process is going to be killed