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

Commit 1be30e14 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Adds caller check to getAllPackages()" into sc-dev

parents 2bde0ac1 ad9bbd8c
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -8949,6 +8949,7 @@ public class PackageManagerService extends IPackageManager.Stub
    @Override
    public List<String> getAllPackages() {
        enforceSystemOrRootOrShell("getAllPackages is limited to privileged callers");
        final int callingUid = Binder.getCallingUid();
        final int callingUserId = UserHandle.getUserId(callingUid);
        synchronized (mLock) {