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

Commit de07e374 authored by Glenn Kasten's avatar Glenn Kasten
Browse files

Allow capture by root for command-line native testing

Change-Id: I3cafd70b7770c7e4b578d39a8d570572829f2c59
parent 0eafa9d8
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -53,6 +53,10 @@ bool recordingAllowed(const String16& opPackageName) {
    }

    const uid_t uid = IPCThreadState::self()->getCallingUid();

    // To permit command-line native tests
    if (uid == AID_ROOT) return true;

    String16 checkedOpPackageName = opPackageName;

    // In some cases the calling code has no access to the package it runs under.