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

Commit 346c55bd authored by Makoto Onuki's avatar Makoto Onuki Committed by android-build-merger
Browse files

Merge "Avoid NPE in AM.getMyMemoryState()" into pi-dev

am: 29c5266d

Change-Id: Ia37099ed51b1b9bbf2af5dc9deab74494c5de2da
parents 539f6930 29c5266d
Loading
Loading
Loading
Loading
+7 −2
Original line number Diff line number Diff line
@@ -15821,7 +15821,10 @@ public class ActivityManagerService extends IActivityManager.Stub
    }
    @Override
    public void getMyMemoryState(ActivityManager.RunningAppProcessInfo outInfo) {
    public void getMyMemoryState(ActivityManager.RunningAppProcessInfo outState) {
        if (outState == null) {
            throw new IllegalArgumentException("outState is null");
        }
        enforceNotIsolatedCaller("getMyMemoryState");
        final int callingUid = Binder.getCallingUid();
@@ -15832,7 +15835,9 @@ public class ActivityManagerService extends IActivityManager.Stub
            synchronized (mPidsSelfLocked) {
                proc = mPidsSelfLocked.get(Binder.getCallingPid());
            }
            fillInProcMemInfo(proc, outInfo, clientTargetSdk);
            if (proc != null) {
                fillInProcMemInfo(proc, outState, clientTargetSdk);
            }
        }
    }