@@ -235,7 +235,7 @@ void VMStructs::init_constants() {
235235 DECLARE_INT_CONSTANTS_DO (READ_CONSTANT )
236236 }
237237 }
238- // Sepcial case
238+ // Special case
239239 _frame_entry_frame_call_wrapper_offset *= sizeof (uintptr_t );
240240
241241
@@ -287,9 +287,9 @@ void VMStructs::verify_offsets() {
287287 assert (var != field_type##_value);
288288#define VERSION_FIELD_WITH_VERSION (var, field_type, min_ver, max_ver, names ) \
289289 assert (hotspot_version < min_ver || hotspot_version > max_ver || var != field_type##_value);
290-
291290 DECLARE_TYPE_FILED_DO (DO_NOTHING , VERIFY_FIELD , VERSION_FIELD_WITH_VERSION , DO_NOTHING )
292- #undef VERIFY_OFFSET_OR_ADDRESS
291+ #undef VERSION_FIELD_WITH_VERSION
292+ #undef VERIFY_FIELD
293293#undef DO_NOTHING
294294#undef offset_value
295295#undef address_value
@@ -574,7 +574,7 @@ const void *VMStructs::findHeapUsageFunc() {
574574 }
575575 flag = VMFlag::find (" UseZGC" , {VMFlag::Type::Bool});
576576 if (flag != NULL && flag->get () && VM::hotspot_version () < 21 ) {
577- // acessing this method in JDK 21 (generational ZGC) wil cause SIGSEGV
577+ // accessing this method in JDK 21 (generational ZGC) will cause SIGSEGV
578578 return _libjvm->findSymbol (" _ZN14ZCollectedHeap12memory_usageEv" );
579579 }
580580 return _libjvm->findSymbol (" _ZN13CollectedHeap12memory_usageEv" );
@@ -609,8 +609,8 @@ void JNICALL VMStructs::NativeMethodBind(jvmtiEnv *jvmti, JNIEnv *jni, jthread t
609609 tmpDelayed = (void **)malloc (tmpCounter * sizeof (void *) * 2 );
610610 memcpy (tmpDelayed, delayed, tmpCounter * sizeof (void *) * 2 );
611611 delayedCounter = 0 ;
612- delayed = NULL ;
613612 free (delayed);
613+ delayed = NULL ;
614614 }
615615 _lock.unlock ();
616616 // if there was a delayed list, we check it now, not blocking on the lock
@@ -623,7 +623,7 @@ void JNICALL VMStructs::NativeMethodBind(jvmtiEnv *jvmti, JNIEnv *jni, jthread t
623623 free (tmpDelayed);
624624 }
625625 } else {
626- _lock.unlock ();
626+ _lock.lock ();
627627 if (delayed != NULL ) {
628628 delayed[delayedCounter] = method;
629629 delayed[delayedCounter + 1 ] = address;
0 commit comments