Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4d096cf5 authored by Robert Greenwalt's avatar Robert Greenwalt Committed by android-build-merger
Browse files

Check permissions on getDeviceId. am: 79eecef6 am: a9242206

am: 9c3a86f0

* commit '9c3a86f0':
  Check permissions on getDeviceId.
parents f5bd5e9b 9c3a86f0
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -90,6 +90,9 @@ public class PhoneSubInfoController extends IPhoneSubInfo.Stub {

        final Phone phone = getPhone(phoneId);
        if (phone != null) {
            phone.getContext().enforceCallingOrSelfPermission(
                    android.Manifest.permission.READ_PHONE_STATE,
                    "Requires READ_PHONE_STATE");
            return phone.getDeviceId();
        } else {
            Rlog.e(TAG,"getDeviceIdForPhone phone " + phoneId + " is null");