From b76a3614da4402875be2619ea0dcd3fb17fc9e1d Mon Sep 17 00:00:00 2001 From: vvb2060 Date: Sun, 5 Dec 2021 17:41:50 +0800 Subject: [PATCH] Fix isolated process comparisons --- .../java/com/topjohnwu/magisk/ui/deny/AppProcessInfo.kt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/src/main/java/com/topjohnwu/magisk/ui/deny/AppProcessInfo.kt b/app/src/main/java/com/topjohnwu/magisk/ui/deny/AppProcessInfo.kt index 3a3112b41..416f6c8d9 100644 --- a/app/src/main/java/com/topjohnwu/magisk/ui/deny/AppProcessInfo.kt +++ b/app/src/main/java/com/topjohnwu/magisk/ui/deny/AppProcessInfo.kt @@ -85,7 +85,7 @@ class AppProcessInfo( pm.getPackageArchiveInfo(info.sourceDir, flag) ?: return emptyList() } - val processSet = TreeSet(compareBy{ it.name }) + val processSet = TreeSet(compareBy({ it.name }, { it.isIsolated })) processSet += packageInfo.activities.toProcessList() processSet += packageInfo.services.toProcessList() processSet += packageInfo.receivers.toProcessList() @@ -106,6 +106,6 @@ data class ProcessInfo( val packageName: String, var isEnabled: Boolean ) { - val isIsolated get() = packageName == ISOLATED_MAGIC - val isAppZygote get() = name.endsWith("_zygote") + val isIsolated = packageName == ISOLATED_MAGIC + val isAppZygote = name.endsWith("_zygote") }