Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3dfe7f65 authored by Lenka Trochtova's avatar Lenka Trochtova
Browse files

Throw UnsupportedOperationException when creating ephemeral

user on a system without split system user.

BUG: 27143201

Change-Id: I7b7e634ba7fce576dd72a416e802c80939f05d3e
parent 5dea9e79
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -4970,7 +4970,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub {
        Preconditions.checkNotNull(who, "ComponentName is null");
        // Allow setting this policy to true only if there is a split system user.
        if (forceEphemeralUsers && !mInjector.userManagerIsSplitSystemUser()) {
            throw new IllegalArgumentException(
            throw new UnsupportedOperationException(
                    "Cannot force ephemeral users on systems without split system user.");
        }
        boolean removeAllUsers = false;