Skip to content
Permalink
Browse files
8254874: ZGC: JNIHandleBlock verification failure in stack watermark …
…processing

Reviewed-by: tschatzl, cjplummer, sspitsyn, pliden
  • Loading branch information
stefank committed Oct 19, 2020
1 parent 98a395a commit 672f56695e70c728c56ed6cce79b1d424ceccc59
Showing with 5 additions and 0 deletions.
  1. +5 −0 test/hotspot/jtreg/vmTestbase/nsk/jvmti/scenarios/capability/CM03/cm03t001/cm03t001.cpp
@@ -339,6 +339,10 @@ static int prepare(jvmtiEnv* jvmti, JNIEnv* jni) {
if (!NSK_JNI_VERIFY(jni, (klass = jni->GetObjectClass(thread)) != NULL))
return NSK_FALSE;

/* klass is used by other threads - convert to global handle */
if (!NSK_JNI_VERIFY(jni, (klass = (jclass)jni->NewGlobalRef(klass)) != NULL))
return NSK_FALSE;

/* get tested thread method 'delay' */
if (!NSK_JNI_VERIFY(jni, (method = jni->GetMethodID(klass, "delay", "()V")) != NULL))
return NSK_FALSE;
@@ -811,6 +815,7 @@ agentProc(jvmtiEnv* jvmti, JNIEnv* jni, void* arg) {
nsk_jvmti_setFailStatus();

NSK_TRACE(jni->DeleteGlobalRef(thread));
NSK_TRACE(jni->DeleteGlobalRef(klass));

/* resume debugee and wait for sync */
if (!nsk_jvmti_resumeSync())

1 comment on commit 672f566

@bridgekeeper

This comment has been minimized.

Copy link

@bridgekeeper bridgekeeper bot commented on 672f566 Oct 19, 2020

Please sign in to comment.