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

Commit 2e1192c4 authored by Kevin Han's avatar Kevin Han
Browse files

Add null pointer check to getStopped

PackageSetting is not guaranteed to be non-null which caused test
failures. This adds a null check.

Bug: 184936704
Test: presubmit
Change-Id: Ie58ffa0d9abde5417e4db48389e526eaf43e0cf6
parent d560996d
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -23444,7 +23444,7 @@ public class PackageManagerService extends IPackageManager.Stub
        // writer
        synchronized (mLock) {
            final PackageSetting ps = mSettings.getPackageLPr(packageName);
            if (ps.getStopped(userId) && !stopped) {
            if (ps != null && ps.getStopped(userId) && !stopped) {
                shouldUnhibernate = true;
            }
            if (!shouldFilterApplicationLocked(ps, callingUid, userId)