Created
November 29, 2021 14:25
-
-
Save SeeFlowerX/67d4503e0e521a6711862f65d8494b00 to your computer and use it in GitHub Desktop.
jnitrace patch 避免APP卡死
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Interceptor.attach(dlopenRef, { | |
onEnter:function(args){ | |
this.path = args[0].readCString(); | |
},onLeave:function(retval){ | |
if (this.path != null) { | |
if (checkLibrary(this.path)) { | |
trackedLibs.set(retval.toString(), true); | |
} | |
else { | |
libBlacklist.set(retval.toString(), true); | |
} | |
} | |
} | |
}); | |
// patch for https://github.com/chame1eon/jnitrace-engine/blob/981d4737cc78db5814ca149f32c0ba9252287926/lib/engine.ts#L147 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment