CommandHelper

CommandHelper

46.5k Downloads

Cmdline install fails with Java 11

Pieter12345 opened this issue ยท 1 comments

commented

When running install-cmdline from cmd.exe (ran as administrator) within my user's directory on Windows 10 using OpenJDK 11.0.9.1, installation fails with the following feedback:

C:\Users\Pietje\Programs\MethodScript>java -jar commandhelper-3.3.4-SNAPSHOT-full.jar install-cmdline
java.lang.RuntimeException: Preferences have not been initialized!
        at com.laytonsmith.core.Prefs.prefS(Prefs.java:32)
        at com.laytonsmith.core.Prefs.TelemetryOn(Prefs.java:355)
        at com.laytonsmith.core.telemetry.Telemetry.doNag(Telemetry.java:87)
        at com.laytonsmith.core.Main$InstallCmdlineMode.execute(Main.java:425)
        at com.laytonsmith.core.Main.main(Main.java:243)
jan. 26, 2021 4:56:52 A.M. java.util.prefs.WindowsPreferences <init>
WARNING: Could not open/create prefs root node Software\JavaSoft\Prefs at root 0xffffffff80000002. Windows RegCreateKeyEx(...) returned error code 5.
Exception in thread "main" java.lang.Error: java.lang.NoSuchMethodException: java.util.prefs.WindowsPreferences.WindowsRegOpenKey(int, [B, int)
        at com.laytonsmith.PureUtilities.Common.WinRegistry.<clinit>(WinRegistry.java:74)
        at com.laytonsmith.tools.Interpreter.install(Interpreter.java:1022)
        at com.laytonsmith.core.Main$InstallCmdlineMode.execute(Main.java:427)
        at com.laytonsmith.core.Main.main(Main.java:243)
Caused by: java.lang.NoSuchMethodException: java.util.prefs.WindowsPreferences.WindowsRegOpenKey(int, [B, int)
        at java.base/java.lang.Class.getDeclaredMethod(Class.java:2475)
        at com.laytonsmith.PureUtilities.Common.WinRegistry.<clinit>(WinRegistry.java:38)
        ... 3 more
commented

The WindowsRegOpenKey method signature was changed from int, byte[], int to long, byte[], int here.