Skip to content

JVM arguments from config are silently dropped when any -J flag is present on the command line #129

Description

@YuleDev

Describe the bug
When any -J argument is passed on the command line (e.g.
-J-Duser.home=...), the launcher stops applying JVM arguments saved
via the Configure GUI (settings.json's jvmArguments array) to the
forked/launched client process. Only the explicit -J flag(s) passed
on the command line take effect; configured jvmArguments are silently
dropped rather than merged with the command-line ones.

To Reproduce

  1. Run --configure, set JVM arguments to e.g. -Xmx2048m,
    -Xms2048m.
  2. Confirm settings.json's jvmArguments contains those values.
  3. Launch RuneLite via any wrapper/launcher that passes an unrelated
    -J flag on the command line — e.g. -J-Duser.home=/some/path
    (this is how third-party launchers such as Bolt invoke it).
  4. Inspect the running client process (ps -ef) — the configured
    jvmArguments are absent; only the explicit command-line -J flag
    is present.

Expected behavior
JVM arguments saved via the Configure GUI should still apply even
when other -J flags are present on the command line — merged
together rather than one fully overriding the other.

Environment

  • RuneLite client version: 1.12.33
  • Originally surfaced via Bolt (third-party Linux launcher); traced
    and confirmed by Bolt's maintainer as launcher-side behavior:
    https://codeberg.org/Adamcake/Bolt/issues/78
  • OS: Linux (Nobara/Fedora-based), though the mechanism described
    appears OS-independent

Additional context
Quoting Bolt's maintainer's diagnosis: "RuneLite seems to ignore the
extra jvm arguments if any -J args are passed on the command line,
since command line is usually supposed to override config."

Workaround confirmed effective: manually appending
-J-Xmx2048m -J-Xms2048m -J-XX:MaxGCPauseMillis=15 after an existing
-J-Duser.home=... flag causes the client to correctly receive and
honor the additional arguments (verified via ps -ef showing them in
the running process).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions