Bug 799825 - Remove unused code related to device. r=mrbkap, a=blocking-basecamp
authorVincent Chang <vchang@mozilla.com>
Fri, 02 Nov 2012 11:18:11 +0800
changeset 116627 050e4b2e5074abe4d7197b48a39e373b55f1e624
parent 116626 15071d0ac7e6c5f3a6c418fd3fc056b747407356
child 116628 b110c18131fb8f4e334b11a9ed79d9e9616d5cc3
push id1708
push userakeybl@mozilla.com
push dateMon, 19 Nov 2012 21:10:21 +0000
treeherdermozilla-beta@27b14fe50103 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmrbkap, blocking-basecamp
bugs799825
milestone18.0a2
Bug 799825 - Remove unused code related to device. r=mrbkap, a=blocking-basecamp
dom/wifi/WifiWorker.js
--- a/dom/wifi/WifiWorker.js
+++ b/dom/wifi/WifiWorker.js
@@ -35,24 +35,23 @@ XPCOMUtils.defineLazyServiceGetter(this,
 // A note about errors and error handling in this file:
 // The libraries that we use in this file are intended for C code. For
 // C code, it is natural to return -1 for errors and 0 for success.
 // Therefore, the code that interacts directly with the worker uses this
 // convention (note: command functions do get boolean results since the
 // command always succeeds and we do a string/boolean check for the
 // expected results).
 var WifiManager = (function() {
-  function getSdkVersionAndDevice() {
+  function getSdkVersion() {
     Cu.import("resource://gre/modules/systemlibs.js");
     let sdkVersion = libcutils.property_get("ro.build.version.sdk");
-    return { sdkVersion: parseInt(sdkVersion, 10),
-               device: libcutils.property_get("ro.product.device") };
+    return parseInt(sdkVersion, 10);
   }
 
-  let { sdkVersion, device } = getSdkVersionAndDevice();
+  let sdkVersion = getSdkVersion();
 
   var controlWorker = new ChromeWorker(WIFIWORKER_WORKER);
   var eventWorker = new ChromeWorker(WIFIWORKER_WORKER);
 
   // Callbacks to invoke when a reply arrives from the controlWorker.
   var controlCallbacks = Object.create(null);
   var idgen = 0;
 
@@ -715,17 +714,17 @@ var WifiManager = (function() {
     resetConnections(manager.ifname, function() {
       stopDhcp(manager.ifname, function() {
         callback();
       });
     });
   }
 
   manager.start = function() {
-    debug("detected SDK version " + sdkVersion + " and device " + device);
+    debug("detected SDK version " + sdkVersion);
     connectToSupplicant(connectCallback);
   }
 
   function onconnected() {
     // For now we do our own DHCP. In the future, this should be handed
     // off to the Network Manager.
     runDhcp(manager.ifname, function (data) {
       if (!data) {