Loading core/java/android/app/admin/flags/flags.aconfig +0 −10 Original line number Diff line number Diff line Loading @@ -206,16 +206,6 @@ flag { } } flag { name: "power_exemption_bg_usage_fix" namespace: "enterprise" description: "Ensure aps with EXEMPT_FROM_POWER_RESTRICTIONS can execute in the background" bug: "333379020" metadata { purpose: PURPOSE_BUGFIX } } flag { name: "disallow_user_control_stopped_state_fix" namespace: "enterprise" Loading services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java +1 −3 Original line number Diff line number Diff line Loading @@ -20666,9 +20666,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub { // have OP_RUN_ANY_IN_BACKGROUND app op and won't execute in the background. The // code below grants that app op, and once the exemption is in place, the user // won't be able to disable background usage anymore. if (Flags.powerExemptionBgUsageFix() && exemption == EXEMPT_FROM_POWER_RESTRICTIONS && newMode == MODE_ALLOWED) { if (exemption == EXEMPT_FROM_POWER_RESTRICTIONS && newMode == MODE_ALLOWED) { setBgUsageAppOp(appOpsMgr, appInfo); } } Loading
core/java/android/app/admin/flags/flags.aconfig +0 −10 Original line number Diff line number Diff line Loading @@ -206,16 +206,6 @@ flag { } } flag { name: "power_exemption_bg_usage_fix" namespace: "enterprise" description: "Ensure aps with EXEMPT_FROM_POWER_RESTRICTIONS can execute in the background" bug: "333379020" metadata { purpose: PURPOSE_BUGFIX } } flag { name: "disallow_user_control_stopped_state_fix" namespace: "enterprise" Loading
services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java +1 −3 Original line number Diff line number Diff line Loading @@ -20666,9 +20666,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub { // have OP_RUN_ANY_IN_BACKGROUND app op and won't execute in the background. The // code below grants that app op, and once the exemption is in place, the user // won't be able to disable background usage anymore. if (Flags.powerExemptionBgUsageFix() && exemption == EXEMPT_FROM_POWER_RESTRICTIONS && newMode == MODE_ALLOWED) { if (exemption == EXEMPT_FROM_POWER_RESTRICTIONS && newMode == MODE_ALLOWED) { setBgUsageAppOp(appOpsMgr, appInfo); } }