diff --git a/LaunchServer/src/main/java/pro/gravit/launchserver/asm/ConfigGenerator.java b/LaunchServer/src/main/java/pro/gravit/launchserver/asm/ConfigGenerator.java index c39ecc2a..cb6d9ee2 100644 --- a/LaunchServer/src/main/java/pro/gravit/launchserver/asm/ConfigGenerator.java +++ b/LaunchServer/src/main/java/pro/gravit/launchserver/asm/ConfigGenerator.java @@ -54,13 +54,14 @@ public void setByteArrayListField(String name, List b) { constructor.instructions.add(new InsnNode(Opcodes.DUP)); constructor.instructions.add(new MethodInsnNode(Opcodes.INVOKESPECIAL, "java/util/ArrayList", "", "()V")); for (byte[] value : b) { - constructor.instructions.add(new InsnNode(Opcodes.DUP)); + constructor.instructions.add(new InsnNode(Opcodes.DUP)); // +1-1 constructor.instructions.add(new MethodInsnNode(Opcodes.INVOKESTATIC, "java/util/Base64", "getDecoder", "()Ljava/util/Base64$Decoder;", false)); constructor.instructions.add(NodeUtils.getSafeStringInsnList(Base64.getEncoder().encodeToString(value))); constructor.instructions.add(new MethodInsnNode(Opcodes.INVOKEVIRTUAL, "java/util/Base64$Decoder", "decode", base64DecDesc, false)); - constructor.instructions.add(new MethodInsnNode(Opcodes.INVOKEINTERFACE, "java/util/List", "add", "(Ljava/lang/Object;)Z", false)); + constructor.instructions.add(new MethodInsnNode(Opcodes.INVOKEINTERFACE, "java/util/List", "add", "(Ljava/lang/Object;)Z", true)); constructor.instructions.add(new InsnNode(Opcodes.POP)); } + constructor.instructions.add(new InsnNode(Opcodes.POP)); // needs -1 constructor.instructions.add(new FieldInsnNode(Opcodes.PUTFIELD, configclass.name, name, "Ljava/util/List;")); }