From 65a9d3695b35e011564459ffee1e557859a26c0d Mon Sep 17 00:00:00 2001 From: Alan Bateman Date: Fri, 24 Jan 2014 11:50:33 +0000 Subject: [PATCH] 8032456: vm/jni/Miscellaneous/misc001/misc00101m1/misc00101m1.html failing on OS X Reviewed-by: sla, chegar, psandoz --- jdk/src/solaris/native/common/jni_util_md.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/jdk/src/solaris/native/common/jni_util_md.c b/jdk/src/solaris/native/common/jni_util_md.c index e9e0f4e0f3f..42ab2de0037 100644 --- a/jdk/src/solaris/native/common/jni_util_md.c +++ b/jdk/src/solaris/native/common/jni_util_md.c @@ -23,6 +23,8 @@ * questions. */ +#include + #include "jni.h" #include "jni_util.h" #include "dlfcn.h" @@ -40,7 +42,11 @@ void* getProcessHandle() { if (procHandle != NULL) { return procHandle; } +#ifdef __APPLE__ + procHandle = (void*)dlopen(NULL, RTLD_FIRST); +#else procHandle = (void*)dlopen(NULL, RTLD_LAZY); +#endif return procHandle; }