Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7f7751db authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Remove reference of getActiveLinkproperties" am: 79ddf1af am: fc25cb26

Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1645299

Change-Id: I6ab8cba01e409686202d046dae22658face9d06b
parents ea7be3a4 fc25cb26
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -352,7 +352,10 @@ public class VpnManagerService extends IVpnManager.Stub {
    @Override
    public void startLegacyVpn(VpnProfile profile) {
        int user = UserHandle.getUserId(mDeps.getCallingUid());
        final LinkProperties egress = mCm.getActiveLinkProperties();
        // Note that if the caller is not system (uid >= Process.FIRST_APPLICATION_UID),
        // the code might not work well since getActiveNetwork might return null if the uid is
        // blocked by NetworkPolicyManagerService.
        final LinkProperties egress = mCm.getLinkProperties(mCm.getActiveNetwork());
        if (egress == null) {
            throw new IllegalStateException("Missing active network connection");
        }