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

Commit dc0dd242 authored by Winson Chung's avatar Winson Chung
Browse files

Allow the system recents component to fetch info for user and profiles

- The recents component may need to fetch application info for the current
  user and its profiles.

Bug: 109660818
Test: atest CtsAppSecurityHostTestCases:ApplicationVisibilityTest
Change-Id: I7017d40fd2a7ac0d4f288bec21a4bc5cd93c446e
parent dbc60520
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -4789,7 +4789,8 @@ public class PackageManagerService extends IPackageManager.Stub
            // require the permission to be held; the calling uid and given user id referring
            // to the same user is not sufficient
            mPermissionManager.enforceCrossUserPermission(
                    Binder.getCallingUid(), userId, false, false, true,
                    Binder.getCallingUid(), userId, false, false,
                    !isRecentsAccessingChildProfiles(Binder.getCallingUid(), userId),
                    "MATCH_ANY_USER flag requires INTERACT_ACROSS_USERS permission at "
                    + Debug.getCallers(5));
        } else if ((flags & PackageManager.MATCH_UNINSTALLED_PACKAGES) != 0 && isCallerSystemUser