Keep media sessions for stopping user until the stopping is completed am: f281109786

Change-Id: I7bd5edbb0046fa47e0090211c78045a2a67d08a9
This commit is contained in:
Jaewan Kim
2020-05-21 02:55:15 +00:00
committed by Automerger Merge Worker

View File

@@ -342,13 +342,10 @@ public class MediaSessionService extends SystemService implements Monitor {
updateUser();
}
// Called when the user with the userId is removed.
@Override
public void onStopUser(int userId) {
if (DEBUG) Log.d(TAG, "onStopUser: " + userId);
public void onCleanupUser(int userId) {
if (DEBUG) Log.d(TAG, "onCleanupUser: " + userId);
synchronized (mLock) {
// TODO: Also handle removing user in updateUser() because adding/switching user is
// handled in updateUser().
FullUserRecord user = getFullUserRecordLocked(userId);
if (user != null) {
if (user.mFullUserId == userId) {