
commit 13521a95f08e9e7d8e0a59a56b08911a78d85957 Author: Kathy Brade <brade@pearlcrescent.com> Date: Wed Jun 3 11:41:36 2015 -0400 Bug 16269: add-on compatibility check occurs repeatedly Ensure that update-related browser preferences are written to disk by flushing them during startup. --- firefox/components/main.js | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/firefox/components/main.js b/firefox/components/main.js index fb7a788..d2916db 100644 --- a/firefox/components/main.js +++ b/firefox/components/main.js @@ -66,6 +66,16 @@ MeekHTTPHelper.prototype = { return; try { + // Flush the preferences to disk so that pref values that were + // updated during startup are not lost, e.g., ones related to + // browser updates. + // We do this before we change the network.proxy.socks_remote_dns + // value since we do not want that change to be permanent. + let prefSvc = + Components.classes["@mozilla.org/preferences-service;1"] + .getService(Components.interfaces.nsIPrefService); + prefSvc.savePrefFile(null); + let prefs = Components.classes["@mozilla.org/preferences-service;1"] .getService(Components.interfaces.nsIPrefBranch); // Allow unproxied DNS, working around a Tor Browser patch: