Merge "[ActivityManager] Fix index OOB when updating visible."

This commit is contained in:
Wale Ogunwale
2015-06-18 14:38:20 +00:00
committed by Gerrit Code Review

View File

@@ -1258,6 +1258,10 @@ final class ActivityStack {
}
if (r != starting) {
mStackSupervisor.startSpecificActivityLocked(r, false, false);
if (activityNdx >= activities.size()) {
// Record may be removed if its process needs to restart.
activityNdx = activities.size() - 1;
}
}
} else if (r.visible) {