diff options
| author | 2014-05-14 12:45:18 +0000 | |
|---|---|---|
| committer | 2014-05-14 12:45:18 +0000 | |
| commit | af46637e4044630be6255a5f80c96d63f32a4b79 (patch) | |
| tree | 02e54f0983b0cc8a48664d02f7e6a61886998d04 | |
| parent | 9bc300e98f2f7fbb12b9b37f78bdb8238a816670 (diff) | |
| parent | 79a10584802f327bcfca11c5000658b3be74819d (diff) | |
Merge "Set and clear the default network."
| -rw-r--r-- | services/core/java/com/android/server/ConnectivityService.java | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/services/core/java/com/android/server/ConnectivityService.java b/services/core/java/com/android/server/ConnectivityService.java index 2603395849c4..1826478c0507 100644 --- a/services/core/java/com/android/server/ConnectivityService.java +++ b/services/core/java/com/android/server/ConnectivityService.java @@ -2120,6 +2120,11 @@ public class ConnectivityService extends IConnectivityManager.Stub { log("tryFailover: set mActiveDefaultNetwork=-1, prevNetType=" + prevNetType); } mActiveDefaultNetwork = -1; + try { + mNetd.clearDefaultNetId(); + } catch (Exception e) { + loge("Exception clearing default network :" + e); + } } // don't signal a reconnect for anything lower or equal priority than our @@ -2423,6 +2428,11 @@ public class ConnectivityService extends IConnectivityManager.Stub { } } mActiveDefaultNetwork = newNetType; + try { + mNetd.setDefaultNetId(thisNetId); + } catch (Exception e) { + loge("Exception setting default network :" + e); + } // this will cause us to come up initially as unconnected and switching // to connected after our normal pause unless somebody reports us as reall // disconnected |