Fix incorrect method call to wifiManager in Tether

In the WifiTetherApBandController the incorrect method was
being called to check if the device is 5Ghz compatible. We
were calling is5GhzBandSupported directly, but we were
supposed to call isDualBandSupported instead.

Test: robotests updated
Bug: 110793581
Change-Id: I61d3ff10abedde6196b8e29591ebfd3272dbbcd9
This commit is contained in:
Salvador Martinez
2018-07-09 11:52:34 -07:00
parent f406fd7976
commit 78c3f368c3
2 changed files with 10 additions and 5 deletions

View File

@@ -103,7 +103,7 @@ public class WifiTetherApBandPreferenceController extends WifiTetherBasePreferen
// 3: With Dual mode support we can't have AP_BAND_5GHZ - default to ANY
if (!isDualMode && WifiConfiguration.AP_BAND_ANY == band) {
return WifiConfiguration.AP_BAND_5GHZ;
} else if (!mWifiManager.is5GHzBandSupported() && WifiConfiguration.AP_BAND_5GHZ == band) {
} else if (!is5GhzBandSupported() && WifiConfiguration.AP_BAND_5GHZ == band) {
return WifiConfiguration.AP_BAND_2GHZ;
} else if (isDualMode && WifiConfiguration.AP_BAND_5GHZ == band) {
return WifiConfiguration.AP_BAND_ANY;