Loading services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java +4 −4 Original line number Original line Diff line number Diff line Loading @@ -9089,7 +9089,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub { CallerIdentity caller = getCallerIdentity(who); CallerIdentity caller = getCallerIdentity(who); if (Flags.setAutoTimeEnabledCoexistence()) { if (Flags.setAutoTimeEnabledCoexistence()) { Preconditions.checkCallAuthorization(hasPermission(SET_TIME, caller.getPackageName())); Preconditions.checkCallAuthorization(hasPermission(SET_TIME, callerPackageName)); } else { } else { Objects.requireNonNull(who, "ComponentName is null"); Objects.requireNonNull(who, "ComponentName is null"); Preconditions.checkCallAuthorization(isProfileOwnerOnUser0(caller) Preconditions.checkCallAuthorization(isProfileOwnerOnUser0(caller) Loading Loading @@ -9152,7 +9152,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub { EnforcingAdmin enforcingAdmin = enforcePermissionAndGetEnforcingAdmin( EnforcingAdmin enforcingAdmin = enforcePermissionAndGetEnforcingAdmin( /* who */ null, /* who */ null, SET_TIME, SET_TIME, caller.getPackageName(), callerPackageName, UserHandle.USER_ALL UserHandle.USER_ALL ); ); Integer state = mDevicePolicyEngine.getGlobalPolicySetByAdmin( Integer state = mDevicePolicyEngine.getGlobalPolicySetByAdmin( Loading Loading @@ -9197,7 +9197,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub { CallerIdentity caller = getCallerIdentity(who); CallerIdentity caller = getCallerIdentity(who); if (Flags.setAutoTimeZoneEnabledCoexistence()) { if (Flags.setAutoTimeZoneEnabledCoexistence()) { Preconditions.checkCallAuthorization( Preconditions.checkCallAuthorization( hasPermission(SET_TIME_ZONE, caller.getPackageName())); hasPermission(SET_TIME_ZONE, callerPackageName)); } else { } else { Objects.requireNonNull(who, "ComponentName is null"); Objects.requireNonNull(who, "ComponentName is null"); Preconditions.checkCallAuthorization(isProfileOwnerOnUser0(caller) Preconditions.checkCallAuthorization(isProfileOwnerOnUser0(caller) Loading Loading @@ -9255,7 +9255,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub { EnforcingAdmin enforcingAdmin = enforcePermissionAndGetEnforcingAdmin( EnforcingAdmin enforcingAdmin = enforcePermissionAndGetEnforcingAdmin( /* who */ null, /* who */ null, SET_TIME_ZONE, SET_TIME_ZONE, caller.getPackageName(), callerPackageName, UserHandle.USER_ALL UserHandle.USER_ALL ); ); Integer state = mDevicePolicyEngine.getGlobalPolicySetByAdmin( Integer state = mDevicePolicyEngine.getGlobalPolicySetByAdmin( Loading
services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java +4 −4 Original line number Original line Diff line number Diff line Loading @@ -9089,7 +9089,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub { CallerIdentity caller = getCallerIdentity(who); CallerIdentity caller = getCallerIdentity(who); if (Flags.setAutoTimeEnabledCoexistence()) { if (Flags.setAutoTimeEnabledCoexistence()) { Preconditions.checkCallAuthorization(hasPermission(SET_TIME, caller.getPackageName())); Preconditions.checkCallAuthorization(hasPermission(SET_TIME, callerPackageName)); } else { } else { Objects.requireNonNull(who, "ComponentName is null"); Objects.requireNonNull(who, "ComponentName is null"); Preconditions.checkCallAuthorization(isProfileOwnerOnUser0(caller) Preconditions.checkCallAuthorization(isProfileOwnerOnUser0(caller) Loading Loading @@ -9152,7 +9152,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub { EnforcingAdmin enforcingAdmin = enforcePermissionAndGetEnforcingAdmin( EnforcingAdmin enforcingAdmin = enforcePermissionAndGetEnforcingAdmin( /* who */ null, /* who */ null, SET_TIME, SET_TIME, caller.getPackageName(), callerPackageName, UserHandle.USER_ALL UserHandle.USER_ALL ); ); Integer state = mDevicePolicyEngine.getGlobalPolicySetByAdmin( Integer state = mDevicePolicyEngine.getGlobalPolicySetByAdmin( Loading Loading @@ -9197,7 +9197,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub { CallerIdentity caller = getCallerIdentity(who); CallerIdentity caller = getCallerIdentity(who); if (Flags.setAutoTimeZoneEnabledCoexistence()) { if (Flags.setAutoTimeZoneEnabledCoexistence()) { Preconditions.checkCallAuthorization( Preconditions.checkCallAuthorization( hasPermission(SET_TIME_ZONE, caller.getPackageName())); hasPermission(SET_TIME_ZONE, callerPackageName)); } else { } else { Objects.requireNonNull(who, "ComponentName is null"); Objects.requireNonNull(who, "ComponentName is null"); Preconditions.checkCallAuthorization(isProfileOwnerOnUser0(caller) Preconditions.checkCallAuthorization(isProfileOwnerOnUser0(caller) Loading Loading @@ -9255,7 +9255,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub { EnforcingAdmin enforcingAdmin = enforcePermissionAndGetEnforcingAdmin( EnforcingAdmin enforcingAdmin = enforcePermissionAndGetEnforcingAdmin( /* who */ null, /* who */ null, SET_TIME_ZONE, SET_TIME_ZONE, caller.getPackageName(), callerPackageName, UserHandle.USER_ALL UserHandle.USER_ALL ); ); Integer state = mDevicePolicyEngine.getGlobalPolicySetByAdmin( Integer state = mDevicePolicyEngine.getGlobalPolicySetByAdmin(