The fix adds guards against JVMTI_ERROR_WRONG_PHASE error in event handlers
Testing: hotspot/jtreg/serviceability/jvmti on all platforms ------------- Commit messages: - fix Changes: https://git.openjdk.org/jdk/pull/20699/files Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=20699&range=00 Issue: https://bugs.openjdk.org/browse/JDK-8337317 Stats: 89 lines in 2 files changed: 86 ins; 1 del; 2 mod Patch: https://git.openjdk.org/jdk/pull/20699.diff Fetch: git fetch https://git.openjdk.org/jdk.git pull/20699/head:pull/20699 PR: https://git.openjdk.org/jdk/pull/20699