summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
authorCraig Mautner <cmautner@google.com>2014-05-27 14:22:03 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2014-05-27 14:22:04 +0000
commit8aa29921df684f2a991d12aa360d80ced7dc7b48 (patch)
treeba7572c879fa6779e4b5bba02910f10967994be5 /services
parent6940b361e54d083be38c24bfaa4f168462640d03 (diff)
parent87f851d0bad0183eccbb59b1fb378db9155e4a66 (diff)
downloadframeworks_base-8aa29921df684f2a991d12aa360d80ced7dc7b48.zip
frameworks_base-8aa29921df684f2a991d12aa360d80ced7dc7b48.tar.gz
frameworks_base-8aa29921df684f2a991d12aa360d80ced7dc7b48.tar.bz2
Merge "Only start TaskPersister once." into lmp-preview-dev
Diffstat (limited to 'services')
-rw-r--r--services/core/java/com/android/server/am/ActivityManagerService.java10
1 files changed, 6 insertions, 4 deletions
diff --git a/services/core/java/com/android/server/am/ActivityManagerService.java b/services/core/java/com/android/server/am/ActivityManagerService.java
index 88bebcb..1755472 100644
--- a/services/core/java/com/android/server/am/ActivityManagerService.java
+++ b/services/core/java/com/android/server/am/ActivityManagerService.java
@@ -9574,11 +9574,13 @@ public final class ActivityManagerService extends ActivityManagerNative
return;
}
- mRecentTasks = mTaskPersister.restoreTasksLocked();
- if (!mRecentTasks.isEmpty()) {
- mStackSupervisor.createStackForRestoredTaskHistory(mRecentTasks);
+ if (mRecentTasks == null) {
+ mRecentTasks = mTaskPersister.restoreTasksLocked();
+ if (!mRecentTasks.isEmpty()) {
+ mStackSupervisor.createStackForRestoredTaskHistory(mRecentTasks);
+ }
+ mTaskPersister.startPersisting();
}
- mTaskPersister.startPersisting();
// Check to see if there are any update receivers to run.
if (!mDidUpdate) {