We need to wait until after the VMStart event has arrived before adding the listener. Otherwise if the listener is already installed before the VMStart arrives, it will result in resuming the debuggee after processing the VMStart. We want the debuggee to remain suspended after handling the VMStart. More details in the CR.
Tested by running test on all supported platforms. ------------- Commit messages: - add the listener after the VMStart has arrived Changes: https://git.openjdk.org/jdk/pull/25156/files Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=25156&range=00 Issue: https://bugs.openjdk.org/browse/JDK-8356641 Stats: 9 lines in 1 file changed: 6 ins; 3 del; 0 mod Patch: https://git.openjdk.org/jdk/pull/25156.diff Fetch: git fetch https://git.openjdk.org/jdk.git pull/25156/head:pull/25156 PR: https://git.openjdk.org/jdk/pull/25156