Bug 1299162 - Pass preferences.json to browser.js to avoid disk read. r=rnewman, a=lizzard FIREFOX_49_0b10_BUILD1 FIREFOX_49_0b10_RELEASE
authorMichael Kaply <mozilla@kaply.com>
Fri, 02 Sep 2016 10:49:27 -0700
changeset 342574 77a60bbacb97c2f36815b2c395958a354aa581c9
parent 342573 101e643d0f730b8256c4a8ef8270e57757efa502
child 342575 3d6fce4d6f7baa779bf666162247520aaea7b151
push id1183
push userraliiev@mozilla.com
push dateMon, 05 Sep 2016 20:01:49 +0000
treeherdermozilla-release@3148731bed45 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersrnewman, lizzard
bugs1299162
milestone49.0
Bug 1299162 - Pass preferences.json to browser.js to avoid disk read. r=rnewman, a=lizzard
mobile/android/base/java/org/mozilla/gecko/distribution/Distribution.java
--- a/mobile/android/base/java/org/mozilla/gecko/distribution/Distribution.java
+++ b/mobile/android/base/java/org/mozilla/gecko/distribution/Distribution.java
@@ -222,17 +222,17 @@ public class Distribution {
         ThreadUtils.postToBackgroundThread(new Runnable() {
             @Override
             public void run() {
                 boolean distributionSet = distribution.doInit();
                 if (distributionSet) {
                     String preferencesJSON = "";
                     try {
                         final File descFile = distribution.getDistributionFile("preferences.json");
-                        preferencesJSON = FileUtils.getFileContents(descFile);
+                        preferencesJSON = FileUtils.readStringFromFile(descFile);
                     } catch (IOException e) {
                         // Just send empty string
                     }
                     GeckoAppShell.notifyObservers("Distribution:Set", preferencesJSON);
                 }
             }
         });