lancet
lancet copied to clipboard
@Insert方法下调用被拦截的Log.d未生效
@Proxy("i")
@TargetClass("android.util.Log")
public static int printLog(String tag, String msg) {
msg = msg + "----lancet";
return (int) Origin.call();
}
@TargetClass(value = "android.support.v7.app.AppCompatActivity", scope = Scope.LEAF)
@Insert(value = "onStop", mayCreateSuper = true)
protected void onStop() {
Log.i("ZLOVE", "hello word");
Origin.callVoid();
}
打印出来的是 hello word,而不是hello word----lancet
带有 Lancet 注解的类不会被二次注入,建议调整位置,将Log.i 这句放在非 Hook 类内调用