mirror of
https://github.com/GravitLauncher/Launcher
synced 2024-12-23 09:01:08 +03:00
[FIX] Забытый POP...
This commit is contained in:
parent
f5fe5afe81
commit
5ed233613f
1 changed files with 3 additions and 2 deletions
|
@ -54,13 +54,14 @@ public void setByteArrayListField(String name, List<byte[]> b) {
|
||||||
constructor.instructions.add(new InsnNode(Opcodes.DUP));
|
constructor.instructions.add(new InsnNode(Opcodes.DUP));
|
||||||
constructor.instructions.add(new MethodInsnNode(Opcodes.INVOKESPECIAL, "java/util/ArrayList", "<init>", "()V"));
|
constructor.instructions.add(new MethodInsnNode(Opcodes.INVOKESPECIAL, "java/util/ArrayList", "<init>", "()V"));
|
||||||
for (byte[] value : b) {
|
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(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(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.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));
|
||||||
}
|
}
|
||||||
|
constructor.instructions.add(new InsnNode(Opcodes.POP)); // needs -1
|
||||||
constructor.instructions.add(new FieldInsnNode(Opcodes.PUTFIELD, configclass.name, name, "Ljava/util/List;"));
|
constructor.instructions.add(new FieldInsnNode(Opcodes.PUTFIELD, configclass.name, name, "Ljava/util/List;"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue