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

Commit 85439e91 authored by Siyamed Sinir's avatar Siyamed Sinir Committed by android-build-merger
Browse files

Fix ClipboardService device lock check for cross profile am: 6d79675e am: 095eda93

am: a4f6ca3e

Change-Id: If3b713963f393b7a16352d03c28dced60e2df7db
parents d54bc6a9 a4f6ca3e
Loading
Loading
Loading
Loading
+8 −2
Original line number Diff line number Diff line
@@ -307,8 +307,14 @@ public class ClipboardService extends IClipboard.Stub {
    }

    private boolean isDeviceLocked() {
        final KeyguardManager keyguardManager = mContext.getSystemService(KeyguardManager.class);
        final long token = Binder.clearCallingIdentity();
        try {
            final KeyguardManager keyguardManager = mContext.getSystemService(
                    KeyguardManager.class);
            return keyguardManager != null && keyguardManager.isDeviceLocked();
        } finally {
            Binder.restoreCallingIdentity(token);
        }
    }

    private final void checkUriOwnerLocked(Uri uri, int uid) {