Skip to content

Commit

Permalink
Keep inline hook to fix CorePatch issue
Browse files Browse the repository at this point in the history
It is confirmed that commits between 16c09ce and 75e3005 cause #32
  • Loading branch information
JingMatrix committed Sep 21, 2024
1 parent 0a164a2 commit 05dc4a7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions magisk-loader/src/main/jni/src/magisk_loader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -119,13 +119,13 @@ void MagiskLoader::OnNativeForkSystemServerPost(JNIEnv *env) {
.inline_hooker =
[](auto t, auto r) {
void *bk = nullptr;
return HookPLT(t, r, &bk) == 0 ? bk : nullptr;
return HookInline(t, r, &bk) == 0 ? bk : nullptr;
},
.inline_unhooker = [](auto t) { return UnhookPLT(t) == 0; },
.inline_unhooker = [](auto t) { return UnhookInline(t) == 0; },
.art_symbol_resolver = [](auto symbol) { return GetArt()->getSymbAddress(symbol); },
.art_symbol_prefix_resolver =
[](auto symbol) { return GetArt()->getSymbPrefixFirstAddress(symbol); },
.is_plt_hook = true};
.is_plt_hook = false};
InitArtHooker(env, initInfo);
InitHooks(env);
SetupEntryClass(env);
Expand Down

0 comments on commit 05dc4a7

Please sign in to comment.