mirror of
https://github.com/topjohnwu/Magisk.git
synced 2024-11-23 18:15:30 +00:00
Revert logging after pre specialize
This commit is contained in:
parent
50515d9128
commit
4b5651bd6f
@ -167,10 +167,6 @@ DCL_HOOK_FUNC(int, unshare, int flags) {
|
||||
// A place to clean things up before zygote evaluates fd table
|
||||
DCL_HOOK_FUNC(void, android_log_close) {
|
||||
HookContext::close_fds();
|
||||
if (g_ctx && g_ctx->pid <= 0) {
|
||||
// In child process, no longer be able to access to magiskd
|
||||
android_logging();
|
||||
}
|
||||
old_android_log_close();
|
||||
}
|
||||
|
||||
@ -434,6 +430,9 @@ void HookContext::nativeSpecializeAppProcess_pre() {
|
||||
} else {
|
||||
run_modules_pre(module_fds);
|
||||
}
|
||||
|
||||
close_fds();
|
||||
android_logging();
|
||||
}
|
||||
|
||||
void HookContext::nativeSpecializeAppProcess_post() {
|
||||
@ -461,12 +460,12 @@ void HookContext::nativeForkSystemServer_pre() {
|
||||
ZLOGV("pre forkSystemServer\n");
|
||||
run_modules_pre(remote_get_info(1000, "system_server", &info));
|
||||
close_fds();
|
||||
android_logging();
|
||||
}
|
||||
}
|
||||
|
||||
void HookContext::nativeForkSystemServer_post() {
|
||||
if (pid == 0) {
|
||||
android_logging();
|
||||
ZLOGV("post forkSystemServer\n");
|
||||
run_modules_post();
|
||||
}
|
||||
@ -478,13 +477,11 @@ void HookContext::nativeForkAndSpecialize_pre() {
|
||||
flags[FORK_AND_SPECIALIZE] = true;
|
||||
if (pid == 0) {
|
||||
nativeSpecializeAppProcess_pre();
|
||||
close_fds();
|
||||
}
|
||||
}
|
||||
|
||||
void HookContext::nativeForkAndSpecialize_post() {
|
||||
if (pid == 0) {
|
||||
android_logging();
|
||||
nativeSpecializeAppProcess_post();
|
||||
}
|
||||
fork_post();
|
||||
|
Loading…
Reference in New Issue
Block a user