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

Commit 2f16d7e7 authored by Huihong Luo's avatar Huihong Luo Committed by Android (Google) Code Review
Browse files

Merge "Allow system account to have screenshot permission" into main

parents 592a9fde fcadcff7
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -6882,7 +6882,8 @@ static status_t validateScreenshotPermissions(const CaptureArgs& captureArgs) {
    IPCThreadState* ipc = IPCThreadState::self();
    const int pid = ipc->getCallingPid();
    const int uid = ipc->getCallingUid();
    if (uid == AID_GRAPHICS || PermissionCache::checkPermission(sReadFramebuffer, pid, uid)) {
    if (uid == AID_GRAPHICS || uid == AID_SYSTEM ||
        PermissionCache::checkPermission(sReadFramebuffer, pid, uid)) {
        return OK;
    }