Java.lang.RuntimeException: Error loading class definition
apkunpacker opened this issue · comments
java -jar simplify.jar --max-call-depth 999 --max-address-visits 999 --max-method-visits 999 --ignore-error TestSimplify.apk
Error :
com/test/dec/SketchwareUtil.smali[128,4] null
Exception in thread "main" java.lang.RuntimeException: Error loading class definition: Lcom/test/dec/SketchwareUtil;
at org.cf.smalivm.type.ClassManager.parseClass(ClassManager.java:187)
at org.cf.smalivm.type.ClassManager.parseClassIfNecessary(ClassManager.java:205)
at org.cf.smalivm.type.ClassManager.getVirtualType(ClassManager.java:137)
at org.cf.smalivm.type.ClassManager.getVirtualType(ClassManager.java:158)
at org.cf.smalivm.type.ClassManager.getVirtualClass(ClassManager.java:130)
at org.cf.simplify.Launcher.collectTargetClassNameToMethods(Launcher.java:166)
at org.cf.simplify.Launcher.run(Launcher.java:133)
at org.cf.simplify.Main.main(Main.java:13)
Caused by: java.lang.RuntimeException: Unable to walk: /data/data/com.termux/files/usr/tmp/simplify11836953586600987855/com/test/dec/SketchwareUtil.smali
at org.cf.smalivm.dex.SmaliParser.parse(SmaliParser.java:83)
at org.cf.smalivm.type.ClassManager.parseClass(ClassManager.java:184)
... 7 more
and simplify stopped . i had look to this error prone class but not understand why it giving error
because all tool can parse it as proper .smali file . lost original apk , only this apk left because in this i merged 2 dex into single one as simplify not aware about multidex yet
on Android tool i see error shown as Instruction format Format45cc not supported
which seems similer to JesusFreke/smali#767
This is a smali / dexlib2 issue. You can work around by rewriting the smali / deleting problematic classes. I'll update to the new dexlib version when it becomes available which should be v2.5.3 or higher.
yeah sure . till then closing issue , will try to remove problematic classes
I'll leave it open to remind me to update dexlib versions. ;)
Facing same issue :( , problem is mainly with invoke-polymorphic