Fix null pointer exception

Bug: 2525763
Change-Id: If2f334187af26e0352d754d7e00a9ca3efc5dffa
This commit is contained in:
Irfan Sheriff
2010-03-18 14:29:59 -07:00
parent b127bf2e9c
commit 4f31a00376

View File

@@ -1074,7 +1074,11 @@ public class WifiStateTracker extends NetworkStateTracker {
break;
case EVENT_DEFERRED_RECONNECT:
String BSSID = msg.obj.toString();
/**
* mLastBssid can be null when there is a reconnect
* request on the first BSSID we connect to
*/
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