From: Chris Lattner Date: Thu, 10 Jul 2008 00:52:20 +0000 (+0000) Subject: open plugins with RTLD_GLOBAL, pointed out by Bram Adams. X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=ae55e04d7a89af2a02041ecbf7f46cba753fa8ce;p=oota-llvm.git open plugins with RTLD_GLOBAL, pointed out by Bram Adams. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@53385 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/System/DynamicLibrary.cpp b/lib/System/DynamicLibrary.cpp index 572ba496e19..5e3b6cb5651 100644 --- a/lib/System/DynamicLibrary.cpp +++ b/lib/System/DynamicLibrary.cpp @@ -61,7 +61,7 @@ DynamicLibrary::~DynamicLibrary() { bool DynamicLibrary::LoadLibraryPermanently(const char *Filename, std::string *ErrMsg) { - void *H = dlopen(Filename, RTLD_LAZY); + void *H = dlopen(Filename, RTLD_LAZY|RTLD_GLOBAL); if (H == 0) { if (ErrMsg) *ErrMsg = dlerror();