Skip to content

Commit 480aa97

Browse files
committed
perf: check shizuku
1 parent 3978cdb commit 480aa97

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

app/src/main/kotlin/li/songe/gkd/permission/PermissionState.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -313,6 +313,7 @@ val writeSecureSettingsState by lazy {
313313
}
314314

315315
private fun shizukuCheckGranted(): Boolean {
316+
if (Shizuku.getBinder()?.isBinderAlive != true) return false
316317
val granted = try {
317318
Shizuku.checkSelfPermission() == PackageManager.PERMISSION_GRANTED
318319
} catch (_: Throwable) {

0 commit comments

Comments
 (0)