Loading services/core/java/com/android/server/connectivity/Vpn.java +13 −11 Original line number Diff line number Diff line Loading @@ -2696,22 +2696,24 @@ public class Vpn { // prevent the NetworkManagementEventObserver from killing this VPN based on the // interface going down (which we expect). mInterface = null; if (mConfig != null) { mConfig.interfaze = null; // Set as unroutable to prevent traffic leaking while the interface is down. if (mConfig != null && mConfig.routes != null) { if (mConfig.routes != null) { final List<RouteInfo> oldRoutes = new ArrayList<>(mConfig.routes); mConfig.routes.clear(); for (final RouteInfo route : oldRoutes) { mConfig.routes.add(new RouteInfo(route.getDestination(), null /*gateway*/, null /*iface*/, RTN_UNREACHABLE)); mConfig.routes.add(new RouteInfo(route.getDestination(), null /*gateway*/, null /*iface*/, RTN_UNREACHABLE)); } if (mNetworkAgent != null) { mNetworkAgent.sendLinkProperties(makeLinkProperties()); } } } } resetIkeState(); } Loading Loading
services/core/java/com/android/server/connectivity/Vpn.java +13 −11 Original line number Diff line number Diff line Loading @@ -2696,22 +2696,24 @@ public class Vpn { // prevent the NetworkManagementEventObserver from killing this VPN based on the // interface going down (which we expect). mInterface = null; if (mConfig != null) { mConfig.interfaze = null; // Set as unroutable to prevent traffic leaking while the interface is down. if (mConfig != null && mConfig.routes != null) { if (mConfig.routes != null) { final List<RouteInfo> oldRoutes = new ArrayList<>(mConfig.routes); mConfig.routes.clear(); for (final RouteInfo route : oldRoutes) { mConfig.routes.add(new RouteInfo(route.getDestination(), null /*gateway*/, null /*iface*/, RTN_UNREACHABLE)); mConfig.routes.add(new RouteInfo(route.getDestination(), null /*gateway*/, null /*iface*/, RTN_UNREACHABLE)); } if (mNetworkAgent != null) { mNetworkAgent.sendLinkProperties(makeLinkProperties()); } } } } resetIkeState(); } Loading