diff --git a/jadx-core/src/main/java/jadx/core/dex/instructions/args/ArgType.java b/jadx-core/src/main/java/jadx/core/dex/instructions/args/ArgType.java index 9237ea5cb0b..ca24197e7b5 100644 --- a/jadx-core/src/main/java/jadx/core/dex/instructions/args/ArgType.java +++ b/jadx-core/src/main/java/jadx/core/dex/instructions/args/ArgType.java @@ -13,6 +13,7 @@ import jadx.core.dex.nodes.RootNode; import jadx.core.dex.visitors.typeinference.TypeCompareEnum; import jadx.core.utils.Utils; +import jadx.core.utils.exceptions.JadxRuntimeException; public abstract class ArgType { public static final ArgType INT = primitive(PrimitiveType.INT); @@ -645,6 +646,9 @@ public static ArgType convertFromPrimitiveType(PrimitiveType primitiveType) { } public static ArgType parse(String type) { + if (type == null || type.isEmpty()) { + throw new JadxRuntimeException("Failed to parse type string: " + type); + } char f = type.charAt(0); switch (f) { case 'L': diff --git a/jadx-plugins/jadx-dex-input/src/main/java/jadx/plugins/input/dex/insns/DexInsnFormat.java b/jadx-plugins/jadx-dex-input/src/main/java/jadx/plugins/input/dex/insns/DexInsnFormat.java index 07618abf410..26e70158fc5 100644 --- a/jadx-plugins/jadx-dex-input/src/main/java/jadx/plugins/input/dex/insns/DexInsnFormat.java +++ b/jadx-plugins/jadx-dex-input/src/main/java/jadx/plugins/input/dex/insns/DexInsnFormat.java @@ -293,7 +293,7 @@ public void decode(DexInsnData insn, int opcodeUnit, SectionReader in) { @Override public void skip(DexInsnData insn, SectionReader in) { int size = in.readUShort(); - in.skip(4 + size * 4 * 2); + in.skip(size * 8); insn.setLength(size * 4 + 2); } };