You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
.methodpublic final a(III)V.registers6new-instancev0, Lkik/android/util/PartitionedRecycledViewPool$a;# This should normally read as follows:# invoke-direct {v0}, Lkik/android/util/PartitionedRecycledViewPool$a;-><init>()V# # but, ProGuard is initializing with java/lang/Object## The decompiler then assumes that it is an object being instantiated and loses the actual object type, which is kik.android.util.PartitionedRecycledViewPool.ainvoke-direct {v0}, Ljava/lang/Object;-><init>()Vif-gtp2, p3, :cond_1cnew-instancep2, Ljava/util/ArrayDeque;igetv1, v0, Lkik/android/util/PartitionedRecycledViewPool$a;->a:Iinvoke-direct {p2, v1}, Ljava/util/ArrayDeque;-><init>(I)Viput-objectp2, v0, Lkik/android/util/PartitionedRecycledViewPool$a;->b:Ljava/util/ArrayDeque;iputp3, v0, Lkik/android/util/PartitionedRecycledViewPool$a;->a:Iiget-objectp2, p0, Lkik/android/util/PartitionedRecycledViewPool;->a:Ljava/util/HashMap;invoke-static {p1}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;move-result-objectp1invoke-virtual {p2, p1, v0}, Ljava/util/HashMap;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;.line28return-void:cond_1cnew-instancep1, Ljava/lang/IllegalArgumentException;const-string/jumbop2, "preload size exceeds cache size"invoke-direct {p1, p2}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)Vthrowp1.end method
Jadx version
1.5.0
The text was updated successfully, but these errors were encountered:
What makes this potentially acceptable is the fact that the fields of PartitionedRecycledViewPool$a are not initialized to specific values.
a is an int, and will be init to 0
b is an object type, and will be init to null
So, calling Object.<init> on the allocated memory instance would be sufficient here. I've never seen this in the wild. Could you share a full APK? Are you sure ProGuard is doing this?
I've just verified it with JEB Pro, the result is quite explicit, the alloc and init parts are broken down to warn the user that something is off:
Issue details
Seems as though ProGuard has implemented a new technique by changing the constructor instructions for zero-args constructors.
See the commented sample and the screenshot of the decompiler being confused by it and failing type inference.
Normal (expected opcodes for instantiating an object with a zero-args constructor):
Proguarded:
example.smali
Relevant log output or stacktrace
No response
Provide sample and class/method full name
Jadx version
1.5.0
The text was updated successfully, but these errors were encountered: