summaryrefslogtreecommitdiff
path: root/cmds/dpm
diff options
context:
space:
mode:
authorXiaohui Chen <xiaohuic@google.com>2015-08-26 14:54:34 -0700
committerXiaohui Chen <xiaohuic@google.com>2015-08-27 18:05:21 +0000
commitcc791bc47c004967557c44abe1764f1f2f7aef8b (patch)
treedac0c3e7fb56a41aecac39e4e0713ea791d15008 /cmds/dpm
parent02fc5fef36357467eba22a0ee250a96734daf791 (diff)
More cleanup USER_OWNER
Bug: 19913735 Change-Id: I7fe1bb2a66231b7d1ae0670dff5e2ec736b2e541
Diffstat (limited to 'cmds/dpm')
-rw-r--r--cmds/dpm/src/com/android/commands/dpm/Dpm.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/cmds/dpm/src/com/android/commands/dpm/Dpm.java b/cmds/dpm/src/com/android/commands/dpm/Dpm.java
index f9b3419b0ccd..471fa3bd046e 100644
--- a/cmds/dpm/src/com/android/commands/dpm/Dpm.java
+++ b/cmds/dpm/src/com/android/commands/dpm/Dpm.java
@@ -107,7 +107,7 @@ public final class Dpm extends BaseCommand {
private void runSetDeviceOwner() throws RemoteException {
ComponentName component = parseComponentName(nextArgRequired());
- mDevicePolicyManager.setActiveAdmin(component, true /*refreshing*/, UserHandle.USER_OWNER);
+ mDevicePolicyManager.setActiveAdmin(component, true /*refreshing*/, UserHandle.USER_SYSTEM);
String packageName = component.getPackageName();
try {
@@ -117,7 +117,7 @@ public final class Dpm extends BaseCommand {
}
} catch (Exception e) {
// Need to remove the admin that we just added.
- mDevicePolicyManager.removeActiveAdmin(component, UserHandle.USER_OWNER);
+ mDevicePolicyManager.removeActiveAdmin(component, UserHandle.USER_SYSTEM);
throw e;
}
System.out.println("Success: Device owner set to package " + packageName);