MCPcopy Create free account
hub / github.com/CodingGay/BlackDex / GetArtMethod

Method GetArtMethod

Bcore/src/main/cpp/jnihook/ArtM.cpp:69–78  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

67}
68
69void *ArtM::GetArtMethod(JNIEnv *env, jclass clazz, jmethodID methodId) {
70 if (ArtMethodEnv.api_level >= __ANDROID_API_Q__) {
71 jclass executable = env->FindClass("java/lang/reflect/Executable");
72 jfieldID artId = env->GetFieldID(executable, "artMethod", "J");
73 jobject method = env->ToReflectedMethod(clazz, methodId, true);
74 return reinterpret_cast<void *>(env->GetLongField(method, artId));
75 } else {
76 return methodId;
77 }
78}
79
80void *ArtM::GetArtMethod(JNIEnv *env, jobject method) {
81 if (ArtMethodEnv.api_level >= __ANDROID_API_Q__) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected