diff options
author | TheKodeToad <TheKodeToad@proton.me> | 2022-11-03 18:11:42 +0000 |
---|---|---|
committer | TheKodeToad <TheKodeToad@proton.me> | 2022-11-08 16:37:00 +0000 |
commit | 9931c9a286c1746c1fb290da50ab31c9d7c7d228 (patch) | |
tree | f1960568936c1ba0c0abe467c6a7691a76f87586 | |
parent | 1da834f6507a8c494d38159208471afd5c9a877e (diff) | |
download | PrismLauncher-9931c9a286c1746c1fb290da50ab31c9d7c7d228.tar.gz PrismLauncher-9931c9a286c1746c1fb290da50ab31c9d7c7d228.tar.bz2 PrismLauncher-9931c9a286c1746c1fb290da50ab31c9d7c7d228.zip |
Remove arguments being passed twice
Passing the classpath into stdin has no effect. Java is already provided the classpath with -cp, which pretty much takes up the largest part of the arguments anyway, which leads me to wonder, what's the point of stdin arguments at all?
Signed-off-by: TheKodeToad <TheKodeToad@proton.me>
-rw-r--r-- | launcher/minecraft/MinecraftInstance.cpp | 15 | ||||
-rw-r--r-- | libraries/launcher/org/prismlauncher/EntryPoint.java | 2 |
2 files changed, 1 insertions, 16 deletions
diff --git a/launcher/minecraft/MinecraftInstance.cpp b/launcher/minecraft/MinecraftInstance.cpp index 5a5245ed..39a7198c 100644 --- a/launcher/minecraft/MinecraftInstance.cpp +++ b/launcher/minecraft/MinecraftInstance.cpp @@ -629,21 +629,6 @@ QString MinecraftInstance::createLaunchScript(AuthSessionPtr session, MinecraftS launchScript += "sessionId " + session->session + "\n"; } - // libraries and class path. - { - QStringList jars, nativeJars; - profile->getLibraryFiles(runtimeContext(), jars, nativeJars, getLocalLibraryPath(), binRoot()); - for(auto file: jars) - { - launchScript += "cp " + file + "\n"; - } - for(auto file: nativeJars) - { - launchScript += "ext " + file + "\n"; - } - launchScript += "natives " + getNativePath() + "\n"; - } - for (auto trait : profile->getTraits()) { launchScript += "traits " + trait + "\n"; diff --git a/libraries/launcher/org/prismlauncher/EntryPoint.java b/libraries/launcher/org/prismlauncher/EntryPoint.java index c33ab983..36831179 100644 --- a/libraries/launcher/org/prismlauncher/EntryPoint.java +++ b/libraries/launcher/org/prismlauncher/EntryPoint.java @@ -81,7 +81,6 @@ public final class EntryPoint { if (exitCode != ExitCode.NORMAL) { LOGGER.warning("Exiting with " + exitCode); - // noinspection CallToSystemExit System.exit(exitCode.numericalCode); } } @@ -97,6 +96,7 @@ public final class EntryPoint { return PreLaunchAction.ABORT; else { String[] pair = StringUtils.splitStringPair(' ', input); + if (pair == null) throw new ParseException(String.format( "Could not split input string '%s' by space. All input provided from stdin must be either 'launch', 'abort', or " |