Fix various issues found when testing Mms.
Fix some race conditions (check isTeardownRequested). Fix the passing of mInterfaceName to subtypes (mms, etc). Fix the generation of CONNECTED message to already active subtypes. Fix the enabling of Data in DataConnectionTracker. bug: 2065037
This commit is contained in:
parent
fde2b76814
commit
a52c75ae24
1 changed files with 5 additions and 2 deletions
|
|
@ -513,7 +513,8 @@ public class ConnectivityService extends IConnectivityManager.Stub {
|
|||
mNetRequestersPids[usedNetworkType].add(currentPid);
|
||||
}
|
||||
|
||||
if (ni.isConnectedOrConnecting() == true) {
|
||||
if ((ni.isConnectedOrConnecting() == true) &&
|
||||
!network.isTeardownRequested()) {
|
||||
if (ni.isConnected() == true) {
|
||||
// add the pid-specific dns
|
||||
handleDnsConfigurationChange();
|
||||
|
|
@ -686,6 +687,7 @@ public class ConnectivityService extends IConnectivityManager.Stub {
|
|||
++numConnectedNets;
|
||||
}
|
||||
}
|
||||
if (DBG) Log.d(TAG, "numConnectedNets returning "+numConnectedNets);
|
||||
return numConnectedNets;
|
||||
}
|
||||
|
||||
|
|
@ -792,7 +794,8 @@ public class ConnectivityService extends IConnectivityManager.Stub {
|
|||
if (newNet.isAvailable()) {
|
||||
NetworkInfo switchTo = newNet.getNetworkInfo();
|
||||
switchTo.setFailover(true);
|
||||
if (!switchTo.isConnectedOrConnecting()) {
|
||||
if (!switchTo.isConnectedOrConnecting() ||
|
||||
newNet.isTeardownRequested()) {
|
||||
newNet.reconnect();
|
||||
}
|
||||
if (DBG) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue