skylot / jadx

Dex to Java decompiler
Apache License 2.0
41.81k stars 4.88k forks source link

decompilation error #617

Open fakirpic opened 5 years ago

fakirpic commented 5 years ago

the.zip

Hi, i am just trying to decompile an apk and convert to readable code,

and what i get is that


    static /* synthetic */ class AnonymousClass4 {
        static final /* synthetic */ int[] b = new int[ConnectionStatus.a().length];

        /* JADX WARNING: Missing exception handler attribute for start block: B:25:0x005e */
        /* JADX WARNING: Missing exception handler attribute for start block: B:19:0x0040 */
        /* JADX WARNING: Missing exception handler attribute for start block: B:31:0x007c */
        /* JADX WARNING: Missing exception handler attribute for start block: B:27:0x0068 */
        /* JADX WARNING: Missing exception handler attribute for start block: B:29:0x0072 */
        /* JADX WARNING: Failed to process nested try/catch */
        /* JADX WARNING: Can't wrap try/catch for region: R(27:0|1|2|3|5|6|7|(2:9|10)|11|13|14|15|17|18|(2:19|20)|21|23|24|25|26|27|28|29|30|31|32|34) */
        /* JADX WARNING: Can't wrap try/catch for region: R(26:0|1|2|3|(2:5|6)|7|(2:9|10)|11|13|14|15|17|18|(2:19|20)|21|23|24|25|26|27|28|29|30|31|32|34) */
        /* JADX WARNING: Can't wrap try/catch for region: R(22:0|(2:1|2)|3|(2:5|6)|7|(2:9|10)|11|(2:13|14)|15|17|18|(2:19|20)|21|23|24|25|26|27|28|29|30|(3:31|32|34)) */
        static {
            /*
            com.criticalblue.attestationlibrary.PlatformSpecifics$ConnectionStatus[] r0 = com.criticalblue.attestationlibrary.PlatformSpecifics.ConnectionStatus.a()
            int r0 = r0.length
            int[] r0 = new int[r0]
            b = r0
            r0 = 1
            int[] r1 = b     // Catch:{ NoSuchFieldError -> 0x0014 }
            com.criticalblue.attestationlibrary.PlatformSpecifics$ConnectionStatus r2 = com.criticalblue.attestationlibrary.PlatformSpecifics.ConnectionStatus.CONNECTED     // Catch:{ NoSuchFieldError -> 0x0014 }
            int r2 = r2.ordinal()     // Catch:{ NoSuchFieldError -> 0x0014 }
            r1[r2] = r0     // Catch:{ NoSuchFieldError -> 0x0014 }
        L_0x0014:
            r1 = 2

"com.criticalblue.attestationlibrary.CA3AttestationInternal" part is that a bug or this is what it should like when wanted?

asashour commented 5 years ago

Well, it is expected to have compilable code, otherwise it is a bug.

You can help by providing minimal test case as in here

asashour commented 5 years ago

The method in question, seems to be related to a ConnectionStatus (a) Enum, where oridinal 0 is not set.