diff options
author | Benjamin Franz <bfranz@google.com> | 2015-04-15 08:29:13 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2015-04-15 08:29:15 +0000 |
commit | b4e218832173229ca2cb25e420c557f919a8ef09 (patch) | |
tree | 67d48f7a76d76a1f168723c8a34aec2a3adcd241 | |
parent | 5c1405e10c223261bc3d4fef4671f069cadf760c (diff) | |
parent | 3223106dab67ba38027590a600edaa02efb6e461 (diff) | |
download | frameworks_base-b4e218832173229ca2cb25e420c557f919a8ef09.zip frameworks_base-b4e218832173229ca2cb25e420c557f919a8ef09.tar.gz frameworks_base-b4e218832173229ca2cb25e420c557f919a8ef09.tar.bz2 |
Merge "Fix a SecurityException in setKeyguardEnabledState"
-rw-r--r-- | services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java index c5e1933..7e59943 100644 --- a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java +++ b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java @@ -5817,12 +5817,12 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub { final int userId = UserHandle.getCallingUserId(); LockPatternUtils utils = new LockPatternUtils(mContext); - // disallow disabling the keyguard if a password is currently set - if (!enabled && utils.isSecure(userId)) { - return false; - } long ident = Binder.clearCallingIdentity(); try { + // disallow disabling the keyguard if a password is currently set + if (!enabled && utils.isSecure(userId)) { + return false; + } utils.setLockScreenDisabled(!enabled, userId); } finally { Binder.restoreCallingIdentity(ident); |