OSDN Git Service

Remove activity from stopping activities once resumed.
authorBryce Lee <brycelee@google.com>
Fri, 18 Aug 2017 20:52:31 +0000 (13:52 -0700)
committerBryce Lee <brycelee@google.com>
Fri, 18 Aug 2017 20:52:31 +0000 (13:52 -0700)
commit29a649da5f8097efdb28d6982edbe43091eda44f
tree995a9b669f6d8bcb9538233afbf3f0691672bf32
parentfde112a2eb64c02d46fc0c42a4874f9e0631d611
Remove activity from stopping activities once resumed.

Previously we were waiting for the activity to become visible before
removing from this list. This can lead to a race condition where the
activity is resumed and the stopping activities are cleaned up. If
the activity has not become visible, the resumed activity will be
stopped.

This CL addresses the issue by removing the activity from the
stopping activities list once resume has completed.

Change-Id: Ic33906327e538920961e60064a6ae976864509be
Fixes: 63804822
Test: bit FrameworksServicesTests:com.android.server.am.ActivityStackSupervisorTests#testStoppingActivityRemovedWhenResumed
services/core/java/com/android/server/am/ActivityStackSupervisor.java
services/tests/servicestests/src/com/android/server/am/ActivityStackSupervisorTests.java
services/tests/servicestests/src/com/android/server/am/ActivityTestsBase.java