From 9f09eb405df7a57cfe7fb80a00ae0dddb4d9d6d1 Mon Sep 17 00:00:00 2001 From: zaxar163 Date: Wed, 12 Dec 2018 15:56:00 +0300 Subject: [PATCH] LaunchServer stopped entry fixed. --- .../src/main/java/ru/gravit/launchserver/LaunchServer.java | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/LaunchServer/src/main/java/ru/gravit/launchserver/LaunchServer.java b/LaunchServer/src/main/java/ru/gravit/launchserver/LaunchServer.java index d5d174ea..a5b5fd99 100644 --- a/LaunchServer/src/main/java/ru/gravit/launchserver/LaunchServer.java +++ b/LaunchServer/src/main/java/ru/gravit/launchserver/LaunchServer.java @@ -258,7 +258,8 @@ private PostBuildTransformConf(BlockConfigEntry block, Path coredir) { } } - public static void main(String... args) throws Throwable { + @SuppressWarnings("resource") + public static void main(String... args) throws Throwable { JVMHelper.checkStackTrace(LaunchServer.class); JVMHelper.verifySystemProperties(LaunchServer.class, true); LogHelper.addOutput(IOHelper.WORKING_DIR.resolve("LaunchServer.log")); @@ -268,9 +269,7 @@ public static void main(String... args) throws Throwable { // Start LaunchServer Instant start = Instant.now(); try { - try (LaunchServer lsrv = new LaunchServer(IOHelper.WORKING_DIR)) { - lsrv.run(); - } + new LaunchServer(IOHelper.WORKING_DIR).run(); } catch (Throwable exc) { LogHelper.error(exc); return;