From 3a56ea26730755076cb5bc1d07727c7a4fcb8fd7 Mon Sep 17 00:00:00 2001 From: Andreas Krebbel Date: Fri, 15 Jan 2010 09:09:35 -0800 Subject: ld.so: Adjust the auxv if ld.so is directly invoked. If a binary gets invoked by passing it as argument to ld.so the stack still holds the auxiliary vector of ld.so when entering the _start routine of the executable. So the invocation via ld.so is not fully transparent to the executable. This causes problems if the executable wants to scan the auxv itself. --- sysdeps/generic/ldsodefs.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'sysdeps') diff --git a/sysdeps/generic/ldsodefs.h b/sysdeps/generic/ldsodefs.h index e18e60f73f..230c39a631 100644 --- a/sysdeps/generic/ldsodefs.h +++ b/sysdeps/generic/ldsodefs.h @@ -1,5 +1,5 @@ /* Run-time dynamic linker data structures for loaded ELF shared objects. - Copyright (C) 1995-2006, 2007, 2008, 2009 Free Software Foundation, Inc. + Copyright (C) 1995-2009, 2010 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -1015,7 +1015,8 @@ extern void *_dl_sysdep_read_whole_file (const char *file, size_t *sizep, extern ElfW(Addr) _dl_sysdep_start (void **start_argptr, void (*dl_main) (const ElfW(Phdr) *phdr, ElfW(Word) phnum, - ElfW(Addr) *user_entry)) + ElfW(Addr) *user_entry, + ElfW(auxv_t) *auxv)) attribute_hidden; extern void _dl_sysdep_start_cleanup (void) -- cgit v1.2.3