Исправление автосоздания папки guard

This commit is contained in:
Gravit 2018-10-26 21:58:55 +07:00
parent d2faeec55f
commit 9cdc96eadb
No known key found for this signature in database
GPG key ID: 061981E1E85D3216

View file

@ -2,6 +2,7 @@
import java.io.IOException;
import java.io.InputStream;
import java.nio.file.Files;
import java.nio.file.Path;
import java.util.Arrays;
@ -91,6 +92,8 @@ public static void load()
public static void start(Path path1) throws IOException {
Path path = path1.resolve("guard");
if(!IOHelper.exists(path))
Files.createDirectories(path);
Path avanguard = path.resolve(JVMHelper.JVM_BITS == 64 ? "Avanguard64.dll" : "Avanguard32.dll");
Path wrapper = path.resolve(JVMHelper.JVM_BITS == 64 ? NAME + "64.exe" : NAME + "32.exe");
UnpackHelper.unpack(JVMHelper.JVM_BITS == 64 ? "Avanguard64.dll" : "Avanguard32.dll",avanguard);