diff options
author | Irfan Sheriff <isheriff@google.com> | 2010-06-10 19:04:25 -0700 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2010-06-10 19:04:25 -0700 |
commit | 9e30a6e374c0ac154d6ea256f50597c4b0b63cca (patch) | |
tree | 00bc366de0ac55a0221610e040da192647c72db9 /wifi | |
parent | ee9cdce64e8f9cc6233603fdd3efa6b412cebd41 (diff) | |
parent | 749defb0ca1f250f3ebb12aaf9856dba7ce70ef0 (diff) | |
download | frameworks_base-9e30a6e374c0ac154d6ea256f50597c4b0b63cca.zip frameworks_base-9e30a6e374c0ac154d6ea256f50597c4b0b63cca.tar.gz frameworks_base-9e30a6e374c0ac154d6ea256f50597c4b0b63cca.tar.bz2 |
am 749defb0: am f4f614f5: am 9f2a0115: Merge "Remove indefinite DHCP retries" into froyo
Diffstat (limited to 'wifi')
-rw-r--r-- | wifi/java/android/net/wifi/WifiStateTracker.java | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/wifi/java/android/net/wifi/WifiStateTracker.java b/wifi/java/android/net/wifi/WifiStateTracker.java index 76f6387..2cec996 100644 --- a/wifi/java/android/net/wifi/WifiStateTracker.java +++ b/wifi/java/android/net/wifi/WifiStateTracker.java @@ -156,7 +156,7 @@ public class WifiStateTracker extends Handler implements NetworkStateTracker { * See {@link Settings.Secure#WIFI_MAX_DHCP_RETRY_COUNT}. This is the default * value if a Settings value is not present. */ - private static final int DEFAULT_MAX_DHCP_RETRIES = 2; + private static final int DEFAULT_MAX_DHCP_RETRIES = 9; private static final int DRIVER_POWER_MODE_AUTO = 0; private static final int DRIVER_POWER_MODE_ACTIVE = 1; @@ -1182,16 +1182,15 @@ public class WifiStateTracker extends Handler implements NetworkStateTracker { String BSSID = (msg.obj != null) ? msg.obj.toString() : null; /** * If we've exceeded the maximum number of retries for reconnecting - * to a given network, blacklist the BSSID to allow a connection attempt on - * an alternate BSSID if available + * to a given network, disable the network */ if (mWifiInfo.getSupplicantState() != SupplicantState.UNINITIALIZED) { if (++mReconnectCount > getMaxDhcpRetries()) { if (LOCAL_LOGD) { Log.d(TAG, "Failed reconnect count: " + - mReconnectCount + " Blacklisting " + BSSID); + mReconnectCount + " Disabling " + BSSID); } - addToBlacklist(BSSID); + mWM.disableNetwork(mLastNetworkId); } reconnectCommand(); } |