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

Commit e2e280ec authored by Craig Mautner's avatar Craig Mautner Committed by Android (Google) Code Review
Browse files

Merge "Restore calling identity before checking permission" into lmp-dev

parents 69b86207 85c11a88
Loading
Loading
Loading
Loading
+2 −2
Original line number Original line Diff line number Diff line
@@ -907,6 +907,8 @@ public final class ActivityStackSupervisor implements DisplayListener {
                    requestCode, callingPid, callingUid, callingPackage, startFlags, options,
                    requestCode, callingPid, callingUid, callingPackage, startFlags, options,
                    componentSpecified, null, container);
                    componentSpecified, null, container);


            Binder.restoreCallingIdentity(origId);

            if (stack.mConfigWillChange) {
            if (stack.mConfigWillChange) {
                // If the caller also wants to switch to a new configuration,
                // If the caller also wants to switch to a new configuration,
                // do so now.  This allows a clean switch, as we are waiting
                // do so now.  This allows a clean switch, as we are waiting
@@ -920,8 +922,6 @@ public final class ActivityStackSupervisor implements DisplayListener {
                mService.updateConfigurationLocked(config, null, false, false);
                mService.updateConfigurationLocked(config, null, false, false);
            }
            }


            Binder.restoreCallingIdentity(origId);

            if (outResult != null) {
            if (outResult != null) {
                outResult.result = res;
                outResult.result = res;
                if (res == ActivityManager.START_SUCCESS) {
                if (res == ActivityManager.START_SUCCESS) {