From 1426f399acab3070d38ecc08d16c01b83927729e Mon Sep 17 00:00:00 2001 From: Robbin Ehn Date: Wed, 20 Mar 2024 18:06:29 +0100 Subject: [PATCH] additional fixes --- src/hotspot/os/posix/os_posix.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/hotspot/os/posix/os_posix.cpp b/src/hotspot/os/posix/os_posix.cpp index 1a049c4eba5f5..8ae8c552c44d4 100644 --- a/src/hotspot/os/posix/os_posix.cpp +++ b/src/hotspot/os/posix/os_posix.cpp @@ -711,10 +711,12 @@ void* os::get_default_process_handle() { } void* os::dll_lookup(void* handle, const char* name) { - void* ret = dlsym(handle, name); + void* ret = ::dlsym(handle, name); if (ret == nullptr) { - const char* tmp = dlerror(); - log_debug(os)("Symbol %s not found in dll: %s", name, tmp); + const char* tmp = ::dlerror(); + if (tmp != nullptr) { + log_debug(os)("Symbol %s not found in dll: %s", name, tmp); + } } return ret; }