From 96883c93f390ad9ee3ee92bf58c9f297fd73a8ee Mon Sep 17 00:00:00 2001 From: Lorenzo Colitti Date: Wed, 2 Dec 2020 13:58:47 +0900 Subject: [PATCH] Add comments to the process*FromAgent methods. Test: comment-only change Change-Id: I5ebf6e21d79ed669f85ddf9bf466236d4bd59243 --- services/core/java/com/android/server/ConnectivityService.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/services/core/java/com/android/server/ConnectivityService.java b/services/core/java/com/android/server/ConnectivityService.java index 9b006d050c..65903af492 100644 --- a/services/core/java/com/android/server/ConnectivityService.java +++ b/services/core/java/com/android/server/ConnectivityService.java @@ -6049,6 +6049,7 @@ public class ConnectivityService extends IConnectivityManager.Stub * Stores into |nai| any data coming from the agent that might also be written to the network's * LinkProperties by ConnectivityService itself. This ensures that the data provided by the * agent is not lost when updateLinkProperties is called. + * This method should never alter the agent's LinkProperties, only store data in |nai|. */ private void processLinkPropertiesFromAgent(NetworkAgentInfo nai, LinkProperties lp) { lp.ensureDirectlyConnectedRoutes(); @@ -6350,6 +6351,7 @@ public class ConnectivityService extends IConnectivityManager.Stub * Stores into |nai| any data coming from the agent that might also be written to the network's * NetworkCapabilities by ConnectivityService itself. This ensures that the data provided by the * agent is not lost when updateCapabilities is called. + * This method should never alter the agent's NetworkCapabilities, only store data in |nai|. */ private void processCapabilitiesFromAgent(NetworkAgentInfo nai, NetworkCapabilities nc) { nai.declaredMetered = !nc.hasCapability(NET_CAPABILITY_NOT_METERED);