diff options
-rw-r--r-- | services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java index 043fab4..7381e5e 100644 --- a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java +++ b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java @@ -840,7 +840,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub { mContext.sendOrderedBroadcastAsUser(intent, admin.getUserHandle(), null, result, mHandler, Activity.RESULT_OK, null, null); } else { - mContext.sendBroadcastAsUser(intent, UserHandle.OWNER); + mContext.sendBroadcastAsUser(intent, admin.getUserHandle()); } } @@ -3123,6 +3123,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub { intent.putExtra(Intent.EXTRA_USER, new UserHandle(UserHandle.getCallingUserId())); intent.addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY | Intent.FLAG_RECEIVER_FOREGROUND); + // TODO This should send to parent of profile (which is always owner at the moment). mContext.sendBroadcastAsUser(intent, UserHandle.OWNER); } finally { restoreCallingIdentity(id); |