From d8405f0d05e86eca814039a3ad65a73cd75e06cb Mon Sep 17 00:00:00 2001 From: topjohnwu Date: Sun, 12 Aug 2018 00:16:59 +0800 Subject: [PATCH] Make recovery installed on on system_root devices normal --- native/jni/core/magiskinit.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/native/jni/core/magiskinit.c b/native/jni/core/magiskinit.c index 7ff987425..84b5fd343 100644 --- a/native/jni/core/magiskinit.c +++ b/native/jni/core/magiskinit.c @@ -374,8 +374,11 @@ int main(int argc, char *argv[]) { } // Do not go further if system_root device is booting as recovery - if (!cmd.skip_initramfs && access("/sbin/recovery", F_OK) == 0) + if (!cmd.skip_initramfs && access("/sbin/recovery", F_OK) == 0) { + // Remove Magisk traces + rm_rf("/.backup"); goto exec_init; + } /* ************ * Early Mount