Skip to content

Commit

Permalink
fix loader for QQ 8.9.68
Browse files Browse the repository at this point in the history
  • Loading branch information
teble committed Dec 22, 2023
1 parent e569ee2 commit ad3846e
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions app/src/main/java/me/teble/xposed/autodaily/hook/MainHook.kt
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import com.github.kyuubiran.ezxhelper.utils.emptyParam
import com.github.kyuubiran.ezxhelper.utils.findMethod
import com.github.kyuubiran.ezxhelper.utils.hookAfter
import com.github.kyuubiran.ezxhelper.utils.hookBefore
import com.github.kyuubiran.ezxhelper.utils.isPublic
import de.robv.android.xposed.IXposedHookLoadPackage
import de.robv.android.xposed.IXposedHookZygoteInit
import de.robv.android.xposed.callbacks.XC_LoadPackage.LoadPackageParam
Expand Down Expand Up @@ -227,8 +228,9 @@ class MainHook : IXposedHookLoadPackage, IXposedHookZygoteInit {
// for NT QQ
val cKernelInitTask = cl.loadClass("com.tencent.mobileqq.startup.task.KernelInitTask")
val method = cKernelInitTask.declaredMethods.first {
it.name == "run" && it.parameterTypes.size == 1 && it.parameterTypes[0] == Context::class.java
}
it.returnType == Void.TYPE &&
it.parameterTypes.size == 1 && it.parameterTypes[0] == Context::class.java
} ?: throw NoSuchMethodException("KernelInitTask.run(Context)")
method.isAccessible = true
return method
}
Expand Down

0 comments on commit ad3846e

Please sign in to comment.