Skip to content

Commit 9b69c82

Browse files
authored
Fix OpenJ9 detection (#96)
1 parent d63537c commit 9b69c82

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/main/java/cpw/mods/modlauncher/Launcher.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -65,12 +65,12 @@ private Launcher() {
6565
}
6666

6767
public static void main(String... args) {
68-
if (System.getProperty("java.vendor").contains("OpenJ9")) {
68+
if (System.getProperty("java.vm.name").contains("OpenJ9")) {
6969
System.err.printf("""
7070
You are attempting to run with an unsupported Java Virtual Machine : %s
7171
Please visit https://adoptopenjdk.net and install the HotSpot variant.
7272
OpenJ9 is incompatible with several of the transformation behaviours that we rely on to work.
73-
""", System.getProperty("java.vendor"));
73+
""", System.getProperty("java.vm.name"));
7474
throw new IllegalStateException("Open J9 is not supported");
7575
}
7676
LogManager.getLogger().info(MODLAUNCHER,"ModLauncher running: args {}", () -> LaunchServiceHandler.hideAccessToken(args));

0 commit comments

Comments
 (0)