AndFix不支持修改Activity中的private方法吗?

q43xntqr  于 2022-11-13  发布在  其他
关注(0)|答案(6)|浏览(189)

我修改Activity中的private方法,在中兴G720T手机(4.4.4,dalvik)上测试通过,但在5.0以上的手机如oppo r9、米5、魅族pro5、华为honor7、三星S4手机上崩溃,报错如下,是不支持修改art模式的private方法吗?
AndroidRuntime: FATAL EXCEPTION: main
Process: com.ucs, PID: 14275
java.lang.IncompatibleClassChangeError: The method 'void com.app.activity.customer.CustomerListActivity_CF.a()' was expected to be of type direct but instead was found to be of type virtual (declaration of 'java.lang.reflect.ArtMethod' appears in /system/framework/core-libart.jar)
at com.app.activity.customer.CustomerListActivity.onResume(SourceFile:111)
at android.app.Instrumentation.callActivityOnResume(Instrumentation.java:1292)
at android.app.Activity.performResume(Activity.java:6160)
at android.app.ActivityThread.performResumeActivity(ActivityThread.java:3176)
at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:3223)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2575)
at android.app.ActivityThread.access$800(ActivityThread.java:162)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1446)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:135)
at android.app.ActivityThread.main(ActivityThread.java:5528)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:952)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:747)

brc7rcf0

brc7rcf01#

请问你们解决了吗,我也遇到了同样的问题

2j4z5cfb

2j4z5cfb2#

官方人员没有给出说明,我们不敢用,就放弃了,AndFix只是一个demo,学习下他们思路就好了,感谢他们的无私奉献

rbpvctlc

rbpvctlc3#

最新的0.5.0版本太不稳定了,感觉官方人员维护的频率不像以前高了

wljmcqd8

wljmcqd84#

200个 issues 吓死baby

rkue9o1l

rkue9o1l5#

这个应该是支持的

jv4diomz

jv4diomz6#

使用0.4.1 是支持的

相关问题