diff options
author | Etan Cohen <etancohen@google.com> | 2015-07-13 23:02:07 +0000 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2015-07-13 23:02:07 +0000 |
commit | 686be93854cce44d2dd87148ff8063edc89b6d7b (patch) | |
tree | 743e90f5fb2b30630284ad6b180b6ce1cd3f1bf1 /services | |
parent | 7efb0521ff4af2eeca5c99011ece066848069ffc (diff) | |
parent | c09544bb88ada53494d4a955d0450a22985b4799 (diff) | |
download | frameworks_base-686be93854cce44d2dd87148ff8063edc89b6d7b.zip frameworks_base-686be93854cce44d2dd87148ff8063edc89b6d7b.tar.gz frameworks_base-686be93854cce44d2dd87148ff8063edc89b6d7b.tar.bz2 |
am c09544bb: Merge "Fix filter on CONNECTIVITY_ACTION updates" into mnc-dev
* commit 'c09544bb88ada53494d4a955d0450a22985b4799':
Fix filter on CONNECTIVITY_ACTION updates
Diffstat (limited to 'services')
-rw-r--r-- | services/core/java/com/android/server/ConnectivityService.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/services/core/java/com/android/server/ConnectivityService.java b/services/core/java/com/android/server/ConnectivityService.java index 39c2891..daac521 100644 --- a/services/core/java/com/android/server/ConnectivityService.java +++ b/services/core/java/com/android/server/ConnectivityService.java @@ -559,8 +559,9 @@ public class ConnectivityService extends IConnectivityManager.Stub final DetailedState state = nai.networkInfo.getDetailedState(); for (int type = 0; type < mTypeLists.length; type++) { final ArrayList<NetworkAgentInfo> list = mTypeLists[type]; + final boolean contains = (list != null && list.contains(nai)); final boolean isFirst = (list != null && list.size() > 0 && nai == list.get(0)); - if (isFirst || isDefault) { + if (isFirst || (contains && isDefault)) { maybeLogBroadcast(nai, state, type, isDefault); sendLegacyNetworkBroadcast(nai, state, type); } |