Commit 7244c02a authored by topjohnwu's avatar topjohnwu

Small adjustments

parent 6c229ffa
LOCAL_PATH := $(call my-dir) LOCAL_PATH := $(call my-dir)
# Some handy paths # Some handy paths
JNI_ROOT := jni
EXT_PATH := jni/external EXT_PATH := jni/external
SE_PATH := $(EXT_PATH)/selinux SE_PATH := $(EXT_PATH)/selinux
LIBSELINUX := $(SE_PATH)/libselinux/include LIBSELINUX := $(SE_PATH)/libselinux/include
......
...@@ -140,10 +140,7 @@ void stop_debug_full_log() { ...@@ -140,10 +140,7 @@ void stop_debug_full_log() {
// Stop recording the boot logcat after every boot task is done // Stop recording the boot logcat after every boot task is done
kill(debug_log_pid, SIGTERM); kill(debug_log_pid, SIGTERM);
waitpid(debug_log_pid, NULL, 0); waitpid(debug_log_pid, NULL, 0);
pthread_t thread;
// Start debug thread // Start debug thread
xpthread_create(&thread, NULL, debug_magisk_log_thread, NULL);
pthread_detach(thread);
start_debug_log(); start_debug_log();
#endif #endif
} }
......
...@@ -137,9 +137,9 @@ char *mount_image(const char *img, const char *target) { ...@@ -137,9 +137,9 @@ char *mount_image(const char *img, const char *target) {
if (access(img, F_OK) == -1) if (access(img, F_OK) == -1)
return NULL; return NULL;
if (access(target, F_OK) == -1) { if (access(target, F_OK) == -1) {
if (xmkdir(target, 0755) == -1) { if (xmkdir_p(target, 0755) == -1) {
xmount(NULL, "/", NULL, MS_REMOUNT, NULL); xmount(NULL, "/", NULL, MS_REMOUNT, NULL);
xmkdir(target, 0755); xmkdir_p(target, 0755);
xmount(NULL, "/", NULL, MS_REMOUNT | MS_RDONLY, NULL); xmount(NULL, "/", NULL, MS_REMOUNT | MS_RDONLY, NULL);
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment