Merge "Don't send onLinkPropertiesChanged after onLost for 464xlat." am: a3f12dd52c am: b4e1b65298

Original change: https://android-review.googlesource.com/c/platform/packages/modules/Connectivity/+/1727829

Change-Id: Iad96cfcdd5f385c084be76b3b25ffd10b080df7f
This commit is contained in:
Lorenzo Colitti
2021-06-09 08:33:36 +00:00
committed by Automerger Merge Worker
3 changed files with 6 additions and 12 deletions

View File

@@ -6307,8 +6307,7 @@ public class ConnectivityService extends IConnectivityManager.Stub
// there may not be a strict 1:1 correlation between the two.
private final NetIdManager mNetIdManager;
// NetworkAgentInfo keyed off its connecting messenger
// TODO - eval if we can reduce the number of lists/hashmaps/sparsearrays
// Tracks all NetworkAgents that are currently registered.
// NOTE: Only should be accessed on ConnectivityServiceThread, except dump().
private final ArraySet<NetworkAgentInfo> mNetworkAgentInfos = new ArraySet<>();
@@ -7451,7 +7450,7 @@ public class ConnectivityService extends IConnectivityManager.Stub
public void handleUpdateLinkProperties(NetworkAgentInfo nai, LinkProperties newLp) {
ensureRunningOnConnectivityServiceThread();
if (getNetworkAgentInfoForNetId(nai.network.getNetId()) != nai) {
if (!mNetworkAgentInfos.contains(nai)) {
// Ignore updates for disconnected networks
return;
}