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

Commit 939be877 authored by Makoto Onuki's avatar Makoto Onuki
Browse files

Slightly change the "pre-N" so it's CTS-friendly.

Right now, the value of VERSION_CODES.N is 10000, but I'm writing
a caller app with target SDK level 24 for CTS, and the previous
logic didn't work for it.

Bug 25506830

Change-Id: I73613f30b437fb19406736f897d01d59b1f84c9d
parent e3936dcf
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -3656,7 +3656,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub {
            if (!(isProfileOwner(adminComponent, userHandle)
                    || isDeviceOwner(adminComponent, userHandle))) {
                final boolean preN = getTargetSdk(admin.info.getPackageName(), userHandle)
                        < android.os.Build.VERSION_CODES.N;
                        <= android.os.Build.VERSION_CODES.M;
                // As of N, password resetting to empty/null is not allowed anymore.
                // TODO Should we allow DO/PO to set an empty password?
                if (TextUtils.isEmpty(password)) {