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

Commit f1259565 authored by Roshan Pius's avatar Roshan Pius
Browse files

NetworkStackClient: Use @SystemApi alternative for isSameApp

This introduces an @hide dependency on the wifi stack which is
statically linking services.net library.

Bug: 142935310
Test: Compiles
Change-Id: I0040df6b3392fc68e950364092ed07cf5dc5a00e
(cherry-picked from e1a2455d503917d080038b0e714beb7b3506cbd7)
parent 5c4c9872
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -103,7 +103,7 @@ public class NetworkStackClient {
            // checks here should be kept in sync with PermissionUtil.
            if (caller != Process.SYSTEM_UID
                    && caller != Process.NETWORK_STACK_UID
                    && !UserHandle.isSameApp(caller, Process.BLUETOOTH_UID)) {
                    && UserHandle.getAppId(caller) != Process.BLUETOOTH_UID) {
                throw new SecurityException(
                        "Only the system server should try to bind to the network stack.");
            }