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

Commit 7dadf595 authored by Automerger Merge Worker's avatar Automerger Merge Worker
Browse files

Merge "Fix leaks of personal apps in setApplicationHidden" into rvc-dev am:...

Merge "Fix leaks of personal apps in setApplicationHidden" into rvc-dev am: deae2467 am: 5f0e550a

Change-Id: I60d4ed54ccfc584bf56f8b488bbc4c0da7594d5e
parents a4a648ba 5f0e550a
Loading
Loading
Loading
Loading
+8 −3
Original line number Original line Diff line number Diff line
@@ -10912,9 +10912,14 @@ public class DevicePolicyManagerService extends BaseIDevicePolicyManager {
    private void enforcePackageIsSystemPackage(String packageName, int userId)
    private void enforcePackageIsSystemPackage(String packageName, int userId)
            throws RemoteException {
            throws RemoteException {
        if (!isSystemApp(mIPackageManager, packageName, userId)) {
        boolean isSystem;
            throw new IllegalArgumentException(
        try {
                    "The provided package is not a system package");
            isSystem = isSystemApp(mIPackageManager, packageName, userId);
        } catch (IllegalArgumentException e) {
            isSystem = false;
        }
        if (!isSystem) {
            throw new IllegalArgumentException("The provided package is not a system package");
        }
        }
    }
    }