summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
authorJim Miller <jaggies@google.com>2014-10-17 09:31:03 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2014-10-17 09:31:04 +0000
commit7d96dc6d98774ff9b7cf1370f9a5508c4eac6a85 (patch)
tree1474a806f462879c0f2e0ab624487085921d9f40 /services
parent22fa76dac8de6cfd9e7bc1eb8800f4cddbfc0640 (diff)
parent3836c9a4c145cd683151bd627a22958303a418c2 (diff)
downloadframeworks_base-7d96dc6d98774ff9b7cf1370f9a5508c4eac6a85.zip
frameworks_base-7d96dc6d98774ff9b7cf1370f9a5508c4eac6a85.tar.gz
frameworks_base-7d96dc6d98774ff9b7cf1370f9a5508c4eac6a85.tar.bz2
Merge "Fix getStorageEncryptionStatus() in DevicePolicyManager" into lmp-dev
Diffstat (limited to 'services')
-rw-r--r--services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
index af4ae44..fc5c053 100644
--- a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
+++ b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
@@ -3390,7 +3390,9 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub {
private int getEncryptionStatus() {
String status = SystemProperties.get("ro.crypto.state", "unsupported");
if ("encrypted".equalsIgnoreCase(status)) {
- return DevicePolicyManager.ENCRYPTION_STATUS_ACTIVE;
+ return LockPatternUtils.isDeviceEncrypted()
+ ? DevicePolicyManager.ENCRYPTION_STATUS_ACTIVE
+ : DevicePolicyManager.ENCRYPTION_STATUS_INACTIVE;
} else if ("unencrypted".equalsIgnoreCase(status)) {
return DevicePolicyManager.ENCRYPTION_STATUS_INACTIVE;
} else {