src/hotspot/share/jvmci/jvmciCompilerToVM.cpp
changeset 57492 0fb5cc208e71
parent 55487 79c32c7b0992
child 57499 0e2453f75881
--- a/src/hotspot/share/jvmci/jvmciCompilerToVM.cpp	Tue Jul 02 10:28:20 2019 +0200
+++ b/src/hotspot/share/jvmci/jvmciCompilerToVM.cpp	Thu Jul 18 09:15:26 2019 -0700
@@ -2181,8 +2181,7 @@
 C2V_VMENTRY(void, deleteGlobalHandle, (JNIEnv* env, jobject, jlong h))
   jobject handle = (jobject)(address)h;
   if (handle != NULL) {
-    assert(JVMCI::is_global_handle(handle), "Invalid delete of global JNI handle");
-    *((oop*)handle) = NULL; // Mark the handle as deleted, allocate will reuse it
+    JVMCI::destroy_global(handle);
   }
 }