diff options
Diffstat (limited to 'depends/launcher/org/multimc')
-rw-r--r-- | depends/launcher/org/multimc/Utils.java | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/depends/launcher/org/multimc/Utils.java b/depends/launcher/org/multimc/Utils.java index 1077065a..32cf7919 100644 --- a/depends/launcher/org/multimc/Utils.java +++ b/depends/launcher/org/multimc/Utils.java @@ -235,8 +235,12 @@ public class Utils ZipFile zip = new ZipFile(source); boolean applyHacks = false; - String[] javaVersionElements = System.getProperty("java.version").split("\\."); - int major = Integer.parseInt(javaVersionElements[1]); + String[] javaVersionElements = System.getProperty("java.version").split("[.\\-+]"); + int major = Integer.parseInt(javaVersionElements[0]); + if(major == 1) + { + major = Integer.parseInt(javaVersionElements[1]); + } if (major >= 8) { applyHacks = true; |