Merge "Clear underlying network info in onDefaultNetworkLost()"

This commit is contained in:
Lucas Lin
2022-12-08 05:30:47 +00:00
committed by Gerrit Code Review

View File

@@ -3475,6 +3475,8 @@ public class Vpn {
return; return;
} else { } else {
mActiveNetwork = null; mActiveNetwork = null;
mUnderlyingNetworkCapabilities = null;
mUnderlyingLinkProperties = null;
} }
if (mScheduledHandleNetworkLostFuture != null) { if (mScheduledHandleNetworkLostFuture != null) {
@@ -3664,9 +3666,6 @@ public class Vpn {
scheduleRetryNewIkeSession(); scheduleRetryNewIkeSession();
} }
mUnderlyingNetworkCapabilities = null;
mUnderlyingLinkProperties = null;
// Close all obsolete state, but keep VPN alive incase a usable network comes up. // Close all obsolete state, but keep VPN alive incase a usable network comes up.
// (Mirrors VpnService behavior) // (Mirrors VpnService behavior)
Log.d(TAG, "Resetting state for token: " + mCurrentToken); Log.d(TAG, "Resetting state for token: " + mCurrentToken);