am 66cbec51: am d234dc1f: Merge "Correct check of is user running"

* commit '66cbec512cf31228f8d86171f57cf4e3bcbbd63e':
  Correct check of is user running
This commit is contained in:
Amith Yamasani
2014-12-04 23:24:31 +00:00
committed by Android Git Automerger

View File

@@ -9280,9 +9280,9 @@ public final class ActivityManagerService extends ActivityManagerNative
"Attempt to launch content provider before system ready");
}
// Make sure that the user who owns this provider is started. If not,
// Make sure that the user who owns this provider is running. If not,
// we don't want to allow it to run.
if (mStartedUsers.get(userId) == null) {
if (!isUserRunningLocked(userId, false)) {
Slog.w(TAG, "Unable to launch app "
+ cpi.applicationInfo.packageName + "/"
+ cpi.applicationInfo.uid + " for provider "
@@ -15647,10 +15647,10 @@ public final class ActivityManagerService extends ActivityManagerNative
userId = handleIncomingUser(callingPid, callingUid, userId,
true, ALLOW_NON_FULL, "broadcast", callerPackage);
// Make sure that the user who is receiving this broadcast is started.
// Make sure that the user who is receiving this broadcast is running.
// If not, we will just skip it.
if (userId != UserHandle.USER_ALL && mStartedUsers.get(userId) == null) {
if (userId != UserHandle.USER_ALL && !isUserRunningLocked(userId, false)) {
if (callingUid != Process.SYSTEM_UID || (intent.getFlags()
& Intent.FLAG_RECEIVER_BOOT_UPGRADE) == 0) {
Slog.w(TAG, "Skipping broadcast of " + intent