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

Commit e1feb6b0 authored by Nathan Harold's avatar Nathan Harold
Browse files

Use provided UID for checking Carrier Privileges

Rather than grabbing the UID a second time, which won't work
inside of recursive binder calls, use the provided UID.

Bug: 332563832
Test: atest FrameworksTelephonyTests
Change-Id: Id106b0f718a32d006299a2d1ce1ea69d79b68313
parent a7136d36
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -793,7 +793,7 @@ public final class TelephonyPermissions {
        if (isGranted) return;

        if (allowCarrierPrivilegeOnAnySub) {
            if (checkCarrierPrivilegeForAnySubId(context, Binder.getCallingUid())) return;
            if (checkCarrierPrivilegeForAnySubId(context, uid)) return;
        } else {
            if (checkCarrierPrivilegeForSubId(context, subId)) return;
        }