aboutsummaryrefslogtreecommitdiff
path: root/elf/rtld.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>1998-09-02 12:58:42 +0000
committerUlrich Drepper <drepper@redhat.com>1998-09-02 12:58:42 +0000
commit143e2b96c94c3fd5a2c618db0bad094ce659e743 (patch)
treeeea1289a952261584269f3ffeadf4137a1924706 /elf/rtld.c
parent4ce636da6cf71061410da841e12b27b5f551e879 (diff)
downloadglibc-143e2b96c94c3fd5a2c618db0bad094ce659e743.zip
glibc-143e2b96c94c3fd5a2c618db0bad094ce659e743.tar.gz
glibc-143e2b96c94c3fd5a2c618db0bad094ce659e743.tar.bz2
Update.
1998-09-02 Ulrich Drepper <drepper@cygnus.com> * elf/dl-load.c (fillin_rpath): Handle "/" as RPATH correctly. (_dl_map_object_from_fd): Make NAME argument const. Remove last parameter in _dl_new_object call. (print_search_path): Correct construction of composed path name. (_dl_map_object): Prevent looking at RPATH of the main map twice. Remove last parameter in _dl_new_object call. * elf/dl-object.c: Remove last parameter. Determine whether create origin entry based on empty realname. Handle file in root directory correctly. * elf/ldsodefs.h: Adjust prototype for _dl_new_object. * elf/rtld.c (dl_main): Add comment describing reason for memory leak. Remove last parameter in _dl_new_object call. * sysdeps/generic/dl-origin.h: Handle file in root directory correctly. * sysdeps/unix/sysv/linux/dl-origin.h: Likewise.
Diffstat (limited to 'elf/rtld.c')
-rw-r--r--elf/rtld.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/elf/rtld.c b/elf/rtld.c
index b25fb20..66e5d6c 100644
--- a/elf/rtld.c
+++ b/elf/rtld.c
@@ -417,6 +417,10 @@ of this helper program; chances are you did not intend to run this program.\n\
phdr = main_map->l_phdr;
phent = main_map->l_phnum;
+ /* We overwrite here a pointer to a malloc()ed string. But since
+ the malloc() implementation used at this point is the dummy
+ implementations which has no real free() function it does not
+ makes sense to free the old string first. */
main_map->l_name = (char *) "";
*user_entry = main_map->l_entry;
}
@@ -424,7 +428,7 @@ of this helper program; chances are you did not intend to run this program.\n\
{
/* Create a link_map for the executable itself.
This will be what dlopen on "" returns. */
- main_map = _dl_new_object ((char *) "", "", lt_executable, 0);
+ main_map = _dl_new_object ((char *) "", "", lt_executable);
if (main_map == NULL)
_dl_sysdep_fatal ("cannot allocate memory for link map\n", NULL);
main_map->l_phdr = phdr;