Skip to content

Commit 4451a92

Browse files
author
Doug Simon
committed
8319748: [JVMCI] TestUseCompressedOopsFlagsWithUlimit.java crashes on libgraal
Reviewed-by: never, thartmann
1 parent 7d8adfa commit 4451a92

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/hotspot/share/jvmci/jvmciEnv.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -589,7 +589,9 @@ jboolean JVMCIEnv::transfer_pending_exception(JavaThread* THREAD, JVMCIEnv* peer
589589

590590
JVMCIEnv::~JVMCIEnv() {
591591
if (_init_error_msg != nullptr) {
592-
os::free((void*) _init_error_msg);
592+
// The memory allocated in libjvmci was not allocated with os::malloc
593+
// so must not be freed with os::free.
594+
ALLOW_C_FUNCTION(::free((void*) _init_error_msg));
593595
}
594596
if (_init_error != JNI_OK) {
595597
return;

0 commit comments

Comments
 (0)