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

Commit c2a40600 authored by Kenny Guy's avatar Kenny Guy
Browse files

Revert "Ensure ApplicationInfo is for correct user for system/android package."

Cache in ActivityThread means this still doesn't make sure we will
get an ApplicationInfo for the user being requested. So reverting.

This reverts commit 4a3b8aa08d743b28d53b327597abf03a925641f2.

Bug:17002733
Change-Id: Ie40eb31c4074cea09de3d6a41fe38b14e00eb059
parent 6df8d523
Loading
Loading
Loading
Loading
+1 −3
Original line number Diff line number Diff line
@@ -2121,9 +2121,7 @@ class ContextImpl extends Context {
    public Context createPackageContextAsUser(String packageName, int flags, UserHandle user)
            throws NameNotFoundException {
        final boolean restricted = (flags & CONTEXT_RESTRICTED) == CONTEXT_RESTRICTED;
        if ((packageName.equals("system") || packageName.equals("android"))
                && user.getIdentifier() == UserHandle.getUserId(
                        mPackageInfo.getApplicationInfo().uid)) {
        if (packageName.equals("system") || packageName.equals("android")) {
            return new ContextImpl(this, mMainThread, mPackageInfo, mActivityToken,
                    user, restricted, mDisplay, mOverrideConfiguration);
        }