Loading core/java/android/net/MobileDataStateTracker.java +5 −3 Original line number Diff line number Diff line Loading @@ -145,12 +145,14 @@ public class MobileDataStateTracker extends NetworkStateTracker { if (DBG) Log.d(TAG, mApnType + " Received " + intent.getAction() + " broadcast - state = " + state + ", oldstate = " + mMobileDataState + ", unavailable = " + unavailable + ", reason = " + (reason == null ? "(unspecified)" : reason)); (reason == null ? "(unspecified)" : reason) + ", apnTypeList = " + apnTypeList); // set this regardless of the apnTypeList. It's all the same radio/network // underneath mNetworkInfo.setIsAvailable(!unavailable); if (isApnTypeIncluded(apnTypeList)) { // set this even if the apn isn't Enabled mNetworkInfo.setIsAvailable(!unavailable); if (mEnabled == false) { // if we're not enabled but the APN Type is supported by this connection // we should record the interface name if one's provided. If the user Loading core/java/android/net/NetworkInfo.java +1 −1 Original line number Diff line number Diff line Loading @@ -131,7 +131,7 @@ public class NetworkInfo implements Parcelable { mSubtypeName = subtypeName; setDetailedState(DetailedState.IDLE, null, null); mState = State.UNKNOWN; mIsAvailable = true; mIsAvailable = false; // until we're told otherwise, assume unavailable mIsRoaming = false; } Loading services/java/com/android/server/ConnectivityService.java +7 −13 Original line number Diff line number Diff line Loading @@ -640,20 +640,14 @@ public class ConnectivityService extends IConnectivityManager.Stub { return false; } NetworkStateTracker tracker = mNetTrackers[networkType]; /* * If there's only one connected network, and it's the one requested, * then we don't have to do anything - the requested route already * exists. If it's not the requested network, then it's not possible * to establish the requested route. Finally, if there is more than * one connected network, then we must insert an entry in the routing * table. */ if (getNumConnectedNetworks() > 1) { return tracker.requestRouteToHost(hostAddress); } else { return (mNetAttributes[networkType].isDefault() && tracker.getNetworkInfo().isConnected()); if (!tracker.getNetworkInfo().isConnected() || tracker.isTeardownRequested()) { if (DBG) { Log.d(TAG, "requestRouteToHost on down network (" + networkType + " - dropped"); } return false; } return tracker.requestRouteToHost(hostAddress); } /** Loading Loading
core/java/android/net/MobileDataStateTracker.java +5 −3 Original line number Diff line number Diff line Loading @@ -145,12 +145,14 @@ public class MobileDataStateTracker extends NetworkStateTracker { if (DBG) Log.d(TAG, mApnType + " Received " + intent.getAction() + " broadcast - state = " + state + ", oldstate = " + mMobileDataState + ", unavailable = " + unavailable + ", reason = " + (reason == null ? "(unspecified)" : reason)); (reason == null ? "(unspecified)" : reason) + ", apnTypeList = " + apnTypeList); // set this regardless of the apnTypeList. It's all the same radio/network // underneath mNetworkInfo.setIsAvailable(!unavailable); if (isApnTypeIncluded(apnTypeList)) { // set this even if the apn isn't Enabled mNetworkInfo.setIsAvailable(!unavailable); if (mEnabled == false) { // if we're not enabled but the APN Type is supported by this connection // we should record the interface name if one's provided. If the user Loading
core/java/android/net/NetworkInfo.java +1 −1 Original line number Diff line number Diff line Loading @@ -131,7 +131,7 @@ public class NetworkInfo implements Parcelable { mSubtypeName = subtypeName; setDetailedState(DetailedState.IDLE, null, null); mState = State.UNKNOWN; mIsAvailable = true; mIsAvailable = false; // until we're told otherwise, assume unavailable mIsRoaming = false; } Loading
services/java/com/android/server/ConnectivityService.java +7 −13 Original line number Diff line number Diff line Loading @@ -640,20 +640,14 @@ public class ConnectivityService extends IConnectivityManager.Stub { return false; } NetworkStateTracker tracker = mNetTrackers[networkType]; /* * If there's only one connected network, and it's the one requested, * then we don't have to do anything - the requested route already * exists. If it's not the requested network, then it's not possible * to establish the requested route. Finally, if there is more than * one connected network, then we must insert an entry in the routing * table. */ if (getNumConnectedNetworks() > 1) { return tracker.requestRouteToHost(hostAddress); } else { return (mNetAttributes[networkType].isDefault() && tracker.getNetworkInfo().isConnected()); if (!tracker.getNetworkInfo().isConnected() || tracker.isTeardownRequested()) { if (DBG) { Log.d(TAG, "requestRouteToHost on down network (" + networkType + " - dropped"); } return false; } return tracker.requestRouteToHost(hostAddress); } /** Loading