diff options
Diffstat (limited to 'unix/tclLoadDyld.c')
-rw-r--r-- | unix/tclLoadDyld.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/unix/tclLoadDyld.c b/unix/tclLoadDyld.c index cc02fc4..0a36215 100644 --- a/unix/tclLoadDyld.c +++ b/unix/tclLoadDyld.c @@ -14,7 +14,6 @@ */ #include "tclInt.h" -#include "tclPort.h" #ifndef MODULE_SCOPE #define MODULE_SCOPE extern @@ -60,7 +59,6 @@ extern char *dlerror(void) WEAK_IMPORT_ATTRIBUTE; #include <mach-o/swap.h> #include <mach-o/arch.h> #include <libkern/OSByteOrder.h> -#undef panic #include <mach/mach.h> #include <stdbool.h> @@ -198,6 +196,9 @@ TclpDlopen( if (tclMacOSXDarwinRelease >= 8) #endif { + /* + * Use (RTLD_NOW|RTLD_LOCAL) always, see [Bug #3216070] + */ dlHandle = dlopen(nativePath, RTLD_NOW | RTLD_LOCAL); if (!dlHandle) { /* @@ -208,6 +209,9 @@ TclpDlopen( fileName = Tcl_GetString(pathPtr); nativeFileName = Tcl_UtfToExternalDString(NULL, fileName, -1, &ds); + /* + * Use (RTLD_NOW|RTLD_LOCAL) always, see [Bug #3216070] + */ dlHandle = dlopen(nativeFileName, RTLD_NOW | RTLD_LOCAL); } if (dlHandle) { |