From db6a14cc85cede0769735fdac4da70766989a3ce Mon Sep 17 00:00:00 2001 From: Amith Yamasani Date: Wed, 17 Oct 2012 21:16:52 -0700 Subject: Fix crashes when quickly adding and removing users Make USER_REMOVED an ordered broadcast and send it before the user's state is completely removed from the system. This gives services the opportunity to clean up their state, while still having access to the user's directory and UserInfo object (such as serial number). Tell SyncManager to skip over dying/partially created users. Improve UserManager tests, waiting for users to be removed fully. Bug: 7382252 Change-Id: I93cfb39c9efe6f15087bf83c569a2d154ef27168 --- core/java/android/content/Intent.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'core/java/android/content/Intent.java') diff --git a/core/java/android/content/Intent.java b/core/java/android/content/Intent.java index 97d299a8a582..cf0603e3a84d 100644 --- a/core/java/android/content/Intent.java +++ b/core/java/android/content/Intent.java @@ -2430,7 +2430,8 @@ public class Intent implements Parcelable, Cloneable { /** * Broadcast sent to the system when a user is removed. Carries an extra EXTRA_USER_HANDLE that has * the userHandle of the user. It is sent to all running users except the - * one that has been removed. You must hold + * one that has been removed. The user will not be completely removed until all receivers have + * handled the broadcast. You must hold * {@link android.Manifest.permission#MANAGE_USERS} to receive this broadcast. * @hide */ -- cgit v1.2.3