From 4a12466678e912b621c1e0636ddeeea3cc0cf5a3 Mon Sep 17 00:00:00 2001 From: James Mattis Date: Thu, 25 Mar 2021 10:44:22 -0700 Subject: [PATCH] Change the const for the unreachable network Changing the const used for the unreachable network for per-app functionality for those apps whose traffic for the default network we wish to lose connectivity as dictated by per app network preferences. This is being done as per changes in https://r.android.com/1643182. Bug: 181579204 Test: atest FrameworksNetTests Change-Id: I1bffadfa03a6221096100c9e0457ea00f94027a3 --- .../core/java/com/android/server/ConnectivityService.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/services/core/java/com/android/server/ConnectivityService.java b/services/core/java/com/android/server/ConnectivityService.java index 7ea3738aae002..e3ce7a31b97e2 100644 --- a/services/core/java/com/android/server/ConnectivityService.java +++ b/services/core/java/com/android/server/ConnectivityService.java @@ -6296,8 +6296,8 @@ public class ConnectivityService extends IConnectivityManager.Stub // Request used to optionally keep vehicle internal network always active private final NetworkRequest mDefaultVehicleRequest; - // TODO replace with INetd.DUMMY_NET_ID when available. - private static final int NO_SERVICE_NET_ID = 51; + // TODO replace with INetd.UNREACHABLE_NET_ID when available. + private static final int NO_SERVICE_NET_ID = 52; // Sentinel NAI used to direct apps with default networks that should have no connectivity to a // network with no service. This NAI should never be matched against, nor should any public API // ever return the associated network. For this reason, this NAI is not in the list of available