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

Commit 6a14f3e7 authored by Lalit Kansara's avatar Lalit Kansara Committed by Steve Kondik
Browse files

To fix fatal exception in system process due to NullPointerException.

Null pointer check added to avoid NullPointerException, that was
leading fatal exception in system process hence framework rebooting.

Change-Id: Ia83a6178bd575954345020ef3a792a3445323808
CRs-fixed: 483763
parent 9da961ab
Loading
Loading
Loading
Loading
+8 −6
Original line number Diff line number Diff line
@@ -2015,6 +2015,7 @@ public final class ActivityManagerService extends ActivityManagerNative
            ProcessRecord p = mLruProcesses.get(i);
            // If this app shouldn't be in front of the first N background
            // apps, then skip over that many that are currently hidden.
            if (p != null && p.thread != null) {
                if (skipTop > 0 && p.setAdj >= ProcessList.HIDDEN_APP_MIN_ADJ) {
                    skipTop--;
                }
@@ -2022,6 +2023,7 @@ public final class ActivityManagerService extends ActivityManagerNative
                    mLruProcesses.add(i+1, app);
                    break;
                }
            }
            i--;
        }
        if (i < 0) {