Merge "Change the NetworkInfo for disconnected types." into lmp-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
e2a28e319d
@@ -4761,7 +4761,9 @@ public class ConnectivityService extends IConnectivityManager.Stub {
|
||||
result.setType(networkType);
|
||||
return result;
|
||||
} else {
|
||||
return new NetworkInfo(networkType, 0, "Unknown", "");
|
||||
NetworkInfo result = new NetworkInfo(networkType);
|
||||
result.setDetailedState(NetworkInfo.DetailedState.DISCONNECTED, null, null);
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user