Get device owner app admin

Get device owner app admin when prefentialNetworkService is
configured by device owner

Bug: 219651203
Test: cts
Change-Id: Ic748227e8d12896361216f6ea67776660b752e4e
This commit is contained in:
Sooraj Sasindran
2022-03-18 14:08:06 -07:00
parent 9640eb5e3b
commit 3d14e32aa6

View File

@@ -12269,7 +12269,7 @@ public class DevicePolicyManagerService extends BaseIDevicePolicyManager {
+ " only profile owner or device owner may control the preferential"
+ " network service");
synchronized (getLockObject()) {
final ActiveAdmin requiredAdmin = getProfileOwnerAdminLocked(
final ActiveAdmin requiredAdmin = getDeviceOrProfileOwnerAdminLocked(
caller.getUserId());
if (!requiredAdmin.mPreferentialNetworkServiceConfigs.equals(
preferentialNetworkServiceConfigs)) {
@@ -12299,7 +12299,8 @@ public class DevicePolicyManagerService extends BaseIDevicePolicyManager {
+ " only profile owner or device owner may retrieve the preferential"
+ " network service configurations");
synchronized (getLockObject()) {
final ActiveAdmin requiredAdmin = getProfileOwnerAdminLocked(caller.getUserId());
final ActiveAdmin requiredAdmin = getDeviceOrProfileOwnerAdminLocked(
caller.getUserId());
return requiredAdmin.mPreferentialNetworkServiceConfigs;
}
}