Fix Permissions Reference for getForbiddenPlmns()
Previously this was incorrectly using an internal-only permission
for a public API. Need to use the external version.
Bug: 35261110
Test: TelephonyManagerTest.testGetForbiddenPlmns
Change-Id: Ia4bb90a4cad92f61781128a0a381e2ad087b07e1
diff --git a/src/com/android/phone/PhoneInterfaceManager.java b/src/com/android/phone/PhoneInterfaceManager.java
index 89e484a..b9375a6 100644
--- a/src/com/android/phone/PhoneInterfaceManager.java
+++ b/src/com/android/phone/PhoneInterfaceManager.java
@@ -2392,8 +2392,8 @@
* on a particular subscription
*/
public String[] getForbiddenPlmns(int subId, int appType) {
- mApp.enforceCallingOrSelfPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE,
- "Requires READ_PRIVILEGED_PHONE_STATE");
+ mApp.enforceCallingOrSelfPermission(android.Manifest.permission.READ_PHONE_STATE,
+ "Requires READ_PHONE_STATE");
if (appType != TelephonyManager.APPTYPE_USIM && appType != TelephonyManager.APPTYPE_SIM) {
loge("getForbiddenPlmnList(): App Type must be USIM or SIM");
return null;