Bug 817901 - Wi-Fi hotspot (Open) cannot be turned on with empty password. r=gal a=blocking-basecamp
authorVincent Chang <vchang@mozilla.com>
Wed, 05 Dec 2012 17:57:59 +0800
changeset 118636 f6ddbb034d4af3a55f8043b23ef961ca873fb832
parent 118635 4dc82515e37db821453314ff13a03f16569c437f
child 118637 0955a6092028aec07c19e1c32cbdc0a38b4035f2
push id2871
push usercjones@mozilla.com
push dateThu, 06 Dec 2012 09:04:30 +0000
treeherdermozilla-aurora@0955a6092028 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgal, blocking-basecamp
bugs817901
milestone19.0a2
Bug 817901 - Wi-Fi hotspot (Open) cannot be turned on with empty password. r=gal a=blocking-basecamp
dom/system/gonk/NetworkManager.js
--- a/dom/system/gonk/NetworkManager.js
+++ b/dom/system/gonk/NetworkManager.js
@@ -596,17 +596,17 @@ NetworkManager.prototype = {
     }
     if (securityType != WIFI_SECURITY_TYPE_NONE &&
         securityType != WIFI_SECURITY_TYPE_WPA_PSK &&
         securityType != WIFI_SECURITY_TYPE_WPA2_PSK) {
 
       debug("Invalid security type.");
       return null;
     }
-    if (!securityId) {
+    if (securityType != WIFI_SECURITY_TYPE_NONE && !securityId) {
       debug("Invalid security password.");
       return null;
     }
     // Using the default values here until application supports these settings.
     if (interfaceIp == "" || prefix == "" ||
         dhcpStartIp == "" || dhcpEndIp == "") {
       debug("Invalid subnet information.");
       return null;