summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--services/core/java/com/android/server/am/ActivityStack.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/services/core/java/com/android/server/am/ActivityStack.java b/services/core/java/com/android/server/am/ActivityStack.java
index edc333458c59..60d3d1ec349b 100644
--- a/services/core/java/com/android/server/am/ActivityStack.java
+++ b/services/core/java/com/android/server/am/ActivityStack.java
@@ -1308,7 +1308,9 @@ final class ActivityStack {
// It is possible the activity was freezing the screen before it was paused.
// In that case go ahead and remove the freeze this activity has on the screen
// since it is no longer visible.
- prev.stopFreezingScreenLocked(true /*force*/);
+ if (prev != null) {
+ prev.stopFreezingScreenLocked(true /*force*/);
+ }
mPausingActivity = null;
}