commit | 379eb5c25ffa4879808a6ee4108a08b465cb2928 | [log] [tgz] |
---|---|---|
author | Jackal Guo <jackalguo@google.com> | Wed Jul 22 11:20:39 2020 +0800 |
committer | Jackal Guo <jackalguo@google.com> | Thu Jul 30 05:22:53 2020 +0000 |
tree | 8fa4f8f71d73d69f343b82d9df342f236b015a8c | |
parent | 5c0c5acbb7773eb73f049250e3ecf072c04afbfa [diff] |
Correct protectionToString The information of protectionLevel companion is missing when dumping to string. Bug: 161855740 Test: atest CtsPermission2TestCases:PermissionPolicyTest Change-Id: Ifa9099541df1c287e5883a801ed14d34dad6287b Merged-In: Ifa9099541df1c287e5883a801ed14d34dad6287b
diff --git a/core/java/android/content/pm/PermissionInfo.java b/core/java/android/content/pm/PermissionInfo.java index 5f6befd..e990fd7 100644 --- a/core/java/android/content/pm/PermissionInfo.java +++ b/core/java/android/content/pm/PermissionInfo.java
@@ -525,6 +525,9 @@ if ((level & PermissionInfo.PROTECTION_FLAG_APP_PREDICTOR) != 0) { protLevel += "|appPredictor"; } + if ((level & PermissionInfo.PROTECTION_FLAG_COMPANION) != 0) { + protLevel += "|companion"; + } if ((level & PermissionInfo.PROTECTION_FLAG_RETAIL_DEMO) != 0) { protLevel += "|retailDemo"; }