diff options
author | Makoto Onuki <omakoto@google.com> | 2015-07-16 21:01:37 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2015-07-16 21:01:39 +0000 |
commit | b09b84cafde5ac31f5ef5c79f7a78db540824471 (patch) | |
tree | f4fc121376f1af84117efea3e3e7facb4122e17a /services/core/java | |
parent | db8fa48ed0864125a07f2bbe078fd60abd875ac7 (diff) | |
parent | bc92479a297904856f0815bc14bcb6763bbbf8bf (diff) | |
download | frameworks_base-b09b84cafde5ac31f5ef5c79f7a78db540824471.zip frameworks_base-b09b84cafde5ac31f5ef5c79f7a78db540824471.tar.gz frameworks_base-b09b84cafde5ac31f5ef5c79f7a78db540824471.tar.bz2 |
Merge "DefaultPermission: GET_ACCOUNTS is now in CONTACTS" into mnc-dev
Diffstat (limited to 'services/core/java')
-rw-r--r-- | services/core/java/com/android/server/pm/DefaultPermissionGrantPolicy.java | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/services/core/java/com/android/server/pm/DefaultPermissionGrantPolicy.java b/services/core/java/com/android/server/pm/DefaultPermissionGrantPolicy.java index 7fde68f..b76db41 100644 --- a/services/core/java/com/android/server/pm/DefaultPermissionGrantPolicy.java +++ b/services/core/java/com/android/server/pm/DefaultPermissionGrantPolicy.java @@ -72,6 +72,7 @@ final class DefaultPermissionGrantPolicy { static { CONTACTS_PERMISSIONS.add(Manifest.permission.READ_CONTACTS); CONTACTS_PERMISSIONS.add(Manifest.permission.WRITE_CONTACTS); + CONTACTS_PERMISSIONS.add(Manifest.permission.GET_ACCOUNTS); } private static final Set<String> LOCATION_PERMISSIONS = new ArraySet<>(); @@ -117,11 +118,6 @@ final class DefaultPermissionGrantPolicy { STORAGE_PERMISSIONS.add(Manifest.permission.WRITE_EXTERNAL_STORAGE); } - private static final Set<String> ACCOUNTS_PERMISSIONS = new ArraySet<>(); - static { - ACCOUNTS_PERMISSIONS.add(Manifest.permission.GET_ACCOUNTS); - } - private final PackageManagerService mService; private PackagesProvider mImePackagesProvider; @@ -352,7 +348,6 @@ final class DefaultPermissionGrantPolicy { && doesPackageSupportRuntimePermissions(calendarPackage)) { grantRuntimePermissionsLPw(calendarPackage, CALENDAR_PERMISSIONS, userId); grantRuntimePermissionsLPw(calendarPackage, CONTACTS_PERMISSIONS, userId); - grantRuntimePermissionsLPw(calendarPackage, ACCOUNTS_PERMISSIONS, userId); } // Calendar provider @@ -362,7 +357,6 @@ final class DefaultPermissionGrantPolicy { grantRuntimePermissionsLPw(calendarProviderPackage, CONTACTS_PERMISSIONS, userId); grantRuntimePermissionsLPw(calendarProviderPackage, CALENDAR_PERMISSIONS, true, userId); - grantRuntimePermissionsLPw(calendarProviderPackage, ACCOUNTS_PERMISSIONS, userId); grantRuntimePermissionsLPw(calendarProviderPackage, STORAGE_PERMISSIONS, userId); } @@ -386,7 +380,6 @@ final class DefaultPermissionGrantPolicy { && doesPackageSupportRuntimePermissions(contactsPackage)) { grantRuntimePermissionsLPw(contactsPackage, CONTACTS_PERMISSIONS, userId); grantRuntimePermissionsLPw(contactsPackage, PHONE_PERMISSIONS, userId); - grantRuntimePermissionsLPw(contactsPackage, ACCOUNTS_PERMISSIONS, userId); } // Contacts provider sync adapters @@ -408,7 +401,6 @@ final class DefaultPermissionGrantPolicy { true, userId); grantRuntimePermissionsLPw(contactsProviderPackage, PHONE_PERMISSIONS, true, userId); - grantRuntimePermissionsLPw(contactsProviderPackage, ACCOUNTS_PERMISSIONS, userId); grantRuntimePermissionsLPw(contactsProviderPackage, STORAGE_PERMISSIONS, userId); } @@ -419,7 +411,7 @@ final class DefaultPermissionGrantPolicy { getDefaultSystemHandlerActivityPackageLPr(deviceProvisionIntent, userId); if (deviceProvisionPackage != null && doesPackageSupportRuntimePermissions(deviceProvisionPackage)) { - grantRuntimePermissionsLPw(deviceProvisionPackage, ACCOUNTS_PERMISSIONS, userId); + grantRuntimePermissionsLPw(deviceProvisionPackage, CONTACTS_PERMISSIONS, userId); } // Maps |