summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIngo Weinhold <ingo_weinhold@gmx.de>2009-02-01 18:40:42 (GMT)
committer Ingo Weinhold <ingo_weinhold@gmx.de>2009-02-01 18:40:42 (GMT)
commit47bc66631194a81a111b321583aef292260cb416 (patch)
tree36d3811bf531d84b05e6f972e3e0fdea46486708
parent06828840d7c906261a9545c7eca4d52879ab54c8 (diff)
The assumption that the program image is not used for relocation ofhrev29112
dlopen()ed objects was incorrect. This should fix problems with ports of software with a plugin/add-on interface. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29112 a95241bf-73f2-0310-859d-f6bbb57e9c96
-rw-r--r--src/system/runtime_loader/elf.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/system/runtime_loader/elf.cpp b/src/system/runtime_loader/elf.cpp
index fa29a15..6ba5e55 100644
--- a/src/system/runtime_loader/elf.cpp
+++ b/src/system/runtime_loader/elf.cpp
@@ -2141,10 +2141,9 @@ load_program(char const *path, void **_entry)
if (status < B_OK)
goto err;
- // Set RTLD_GLOBAL on all libraries, but clear it on the program image.
+ // Set RTLD_GLOBAL on all libraries including the program.
// This results in the desired symbol resolution for dlopen()ed libraries.
set_image_flags_recursively(sProgramImage, RTLD_GLOBAL);
- sProgramImage->flags &= ~RTLD_GLOBAL;
status = relocate_dependencies(sProgramImage);
if (status < B_OK)