aboutsummaryrefslogtreecommitdiff
path: root/elf/dl-open.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2007-03-17 17:09:13 +0000
committerUlrich Drepper <drepper@redhat.com>2007-03-17 17:09:13 +0000
commit965cba048c978a2841c537383ed3408259c918f3 (patch)
treee06867399d7e0026645f2a9f69d836629dcc283e /elf/dl-open.c
parentb037a293a48718af30d706c2e18c929d0e69a621 (diff)
downloadglibc-965cba048c978a2841c537383ed3408259c918f3.tar
glibc-965cba048c978a2841c537383ed3408259c918f3.tar.gz
glibc-965cba048c978a2841c537383ed3408259c918f3.tar.bz2
glibc-965cba048c978a2841c537383ed3408259c918f3.zip
* elf/dl-open.c (dl_open_worker): Declare l in 2 differentcvs/fedora-glibc-20070317T2130
smaller scopes. * elf/dl-dst.h (DL_DST_REQ_STATIC): Add l as macro argument. (DL_DST_REQUIRED): Adjust user. * include/dlfcn.h (struct link_map): New forward decl. * inet/getnameinfo.c: Include stddef.h. (getnameinfo): Use offsetof. * time/tst-mktime2.c (do_test): Don't rely on signed wrap. * stdio-common/vfprintf.c (_itoa): Undef before redefining. * string/strerror_l.c: Include stdlib.h.
Diffstat (limited to 'elf/dl-open.c')
-rw-r--r--elf/dl-open.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/elf/dl-open.c b/elf/dl-open.c
index c997521126..259372178b 100644
--- a/elf/dl-open.c
+++ b/elf/dl-open.c
@@ -161,7 +161,7 @@ dl_open_worker (void *a)
struct dl_open_args *args = a;
const char *file = args->file;
int mode = args->mode;
- struct link_map *new, *l;
+ struct link_map *new;
int lazy;
unsigned int i;
bool any_tls = false;
@@ -186,6 +186,7 @@ dl_open_worker (void *a)
By default we assume this is the main application. */
call_map = GL(dl_ns)[LM_ID_BASE]._ns_loaded;
+ struct link_map *l;
for (Lmid_t ns = 0; ns < DL_NNS; ++ns)
for (l = GL(dl_ns)[ns]._ns_loaded; l != NULL; l = l->l_next)
if (caller_dlopen >= (const void *) l->l_map_start
@@ -325,7 +326,7 @@ dl_open_worker (void *a)
/* Relocate the objects loaded. We do this in reverse order so that copy
relocs of earlier objects overwrite the data written by later objects. */
- l = new;
+ struct link_map *l = new;
while (l->l_next)
l = l->l_next;
while (1)