summaryrefslogtreecommitdiff
path: root/ldso/libdl/libdl.c
diff options
context:
space:
mode:
authorJoakim Tjernlund <joakim.tjernlund@transmode.se>2005-03-29 13:47:21 +0000
committerJoakim Tjernlund <joakim.tjernlund@transmode.se>2005-03-29 13:47:21 +0000
commite6816a15ab7d7dbf3ffe75a9a22b4a37909aaf57 (patch)
treeffd16f946ea203cf14cc44c7aaae730cc1032d01 /ldso/libdl/libdl.c
parent223b81b2e707ff3cb99fdf49b7cb6bd1da7f6d21 (diff)
Moved the addition of load address from the fast path
where possible. This will also make ldso smaller. However the patch touches all archs and I have only tested PPC and x86.
Diffstat (limited to 'ldso/libdl/libdl.c')
-rw-r--r--ldso/libdl/libdl.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/ldso/libdl/libdl.c b/ldso/libdl/libdl.c
index 012056a35..e538d89de 100644
--- a/ldso/libdl/libdl.c
+++ b/ldso/libdl/libdl.c
@@ -212,7 +212,7 @@ void *dlopen(const char *libname, int flag)
if (dpnt->d_tag == DT_NEEDED) {
char *name;
- lpntstr = (char*) (tcurr->loadaddr + tcurr->dynamic_info[DT_STRTAB] +
+ lpntstr = (char*) (tcurr->dynamic_info[DT_STRTAB] +
dpnt->d_un.d_val);
name = _dl_get_last_path_component(lpntstr);
tpnt1 = _dl_check_if_named_library_is_loaded(name, 0);
@@ -640,8 +640,8 @@ int dladdr(const void *__address, Dl_info * __info)
ElfW(Addr) sa;
sa = 0;
- symtab = (Elf32_Sym *) (pelf->dynamic_info[DT_SYMTAB] + pelf->loadaddr);
- strtab = (char *) (pelf->dynamic_info[DT_STRTAB] + pelf->loadaddr);
+ symtab = (Elf32_Sym *) (pelf->dynamic_info[DT_SYMTAB]);
+ strtab = (char *) (pelf->dynamic_info[DT_STRTAB]);
sf = 0;
for (hn = 0; hn < pelf->nbucket; hn++) {