diff options
author | Benjamin Franz <bfranz@google.com> | 2015-04-21 09:45:19 +0100 |
---|---|---|
committer | Benjamin Franz <bfranz@google.com> | 2015-04-21 09:45:19 +0100 |
commit | 78c05f97426e941b1a398e0d00b53603603f292b (patch) | |
tree | 132250efcf8580a85edc506215c33dfd727d4e76 /services/devicepolicy | |
parent | 0d703f74d0725748089dba8d1647a2467e63e77d (diff) | |
download | frameworks_base-78c05f97426e941b1a398e0d00b53603603f292b.zip frameworks_base-78c05f97426e941b1a398e0d00b53603603f292b.tar.gz frameworks_base-78c05f97426e941b1a398e0d00b53603603f292b.tar.bz2 |
Check for null packages in setLockTaskPackages
Bug: 20416611
Change-Id: Ibbadc952da29a34de0cf02408093b7bfc01f8779
Diffstat (limited to 'services/devicepolicy')
-rw-r--r-- | services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java | 4 |
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 e22a2cc..8dacf6c 100644 --- a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java +++ b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java @@ -5626,7 +5626,9 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub { if (packages != null) { for (int j = 0; j < packages.length; j++) { String pkg = packages[j]; - policy.mLockTaskPackages.add(pkg); + if (pkg != null) { + policy.mLockTaskPackages.add(pkg); + } } } |