From 9596d0ddf067b6f819ab16916ae9337132cf721c Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Wed, 19 Sep 2001 03:25:37 +0000 Subject: Update. 2001-09-18 Ulrich Drepper * malloc/malloc.c (ptmalloc_init): Handle _environ==NULL. Reported by B. D. Elliott [PR libc/2541]. 2001-09-18 Andreas Schwab * elf/dl-load.c (_dl_map_object_from_fd): Update handling of scope list, now that l_scope is a pointer. * elf/dl-open.c (dl_open_worker): Fix thinko when enlarging the scope list. 2001-09-18 kaz Kojima * sysdeps/sh/dl-machine.h (elf_machine_rela): Fix reverse condition. (elf_machine_rela_relative): Add a missing declaration. 2001-09-18 Jakub Jelinek * sysdeps/unix/sysv/linux/ia64/ldd-rewrite.sed: New. * sysdeps/unix/sysv/linux/s390/ldd-rewrite.sed: New. * sysdeps/unix/sysv/linux/configure.in: Add ia64 and s390 ldd-rewrite scripts. 2001-09-18 Ulrich Drepper * elf/ldd.bash.in: Update copyright message. 2001-09-17 H.J. Lu * hurd/hurdmalloc.c (bcopy): Removed. (realloc): Replace bcopy with memcpy. * hurd/path-lookup.c (file_name_path_scan): Likewise. * resolv/gethnamaddr.c (map_v4v6_address): Likewise. * sunrpc/rpcinfo.c (pmapdump): Likewise. * resolv/gethnamaddr.c (getanswer): Replace bcopy with memmove. (gethostbyaddr): Likewise. * sunrpc/rpcinfo.c (get_inet_address): Likewise. 2001-09-18 Ulrich Drepper * sysdeps/gnu/eval.c: Removed. --- elf/dl-load.c | 2 +- elf/dl-open.c | 10 +++++----- elf/ldd.bash.in | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) (limited to 'elf') diff --git a/elf/dl-load.c b/elf/dl-load.c index 48c78c3..3e5ddc0 100644 --- a/elf/dl-load.c +++ b/elf/dl-load.c @@ -1136,7 +1136,7 @@ _dl_map_object_from_fd (const char *name, int fd, struct filebuf *fbp, /* Now move the existing entries one back. */ memmove (&l->l_scope[1], &l->l_scope[0], - sizeof (l->l_scope) - sizeof (l->l_scope[0])); + (l->l_scope_max - 1) * sizeof (l->l_scope[0])); /* Now add the new entry. */ l->l_scope[0] = &l->l_symbolic_searchlist; diff --git a/elf/dl-open.c b/elf/dl-open.c index f79c317..d10ab8a 100644 --- a/elf/dl-open.c +++ b/elf/dl-open.c @@ -312,7 +312,7 @@ dl_open_worker (void *a) ++runp; } - if (__builtin_expect (cnt + 1 < imap->l_scope_max, 0)) + if (__builtin_expect (cnt + 1 >= imap->l_scope_max, 0)) { /* The 'r_scope' array is too small. Allocate a new one dynamically. */ @@ -327,7 +327,7 @@ dl_open_worker (void *a) _dl_signal_error (ENOMEM, "dlopen", NULL, N_("cannot create scope list")); imap->l_scope = memcpy (newp, imap->l_scope, - cnt * imap->l_scope_max); + cnt * sizeof (imap->l_scope[0])); } else { @@ -339,10 +339,10 @@ dl_open_worker (void *a) N_("cannot create scope list")); imap->l_scope = newp; } - - imap->l_scope[cnt++] = &new->l_searchlist; - imap->l_scope[cnt] = NULL; } + + imap->l_scope[cnt++] = &new->l_searchlist; + imap->l_scope[cnt] = NULL; } /* Run the initializer functions of new objects. */ diff --git a/elf/ldd.bash.in b/elf/ldd.bash.in index b50ee42..0d2a9e7 100644 --- a/elf/ldd.bash.in +++ b/elf/ldd.bash.in @@ -36,7 +36,7 @@ while test $# -gt 0; do case "$1" in --vers | --versi | --versio | --version) echo 'ldd (GNU libc) @VERSION@' - echo $"Copyright (C) 1999 Free Software Foundation, Inc. + echo $"Copyright (C) 2001 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Written by Roland McGrath and Ulrich Drepper." -- cgit v1.1