summaryrefslogtreecommitdiff
path: root/elf
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2007-11-06 01:12:33 +0000
committerUlrich Drepper <drepper@redhat.com>2007-11-06 01:12:33 +0000
commitb92e378086449e2707b8b2fd3d2f50cc0b8871e9 (patch)
treecc81132e476407f88d3262e6d07472079073e761 /elf
parent94a749f69ad4b18250e9aab7292b6e8496e0a065 (diff)
* elf/rtld.c (dl_main): Use the page size to find the map start.
Diffstat (limited to 'elf')
-rw-r--r--elf/rtld.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/elf/rtld.c b/elf/rtld.c
index 6df81fb2c1..98817d9fa0 100644
--- a/elf/rtld.c
+++ b/elf/rtld.c
@@ -1166,7 +1166,8 @@ of this helper program; chances are you did not intend to run this program.\n\
ElfW(Addr) allocend;
/* Remember where the main program starts in memory. */
- mapstart = (main_map->l_addr + (ph->p_vaddr & ~(ph->p_align - 1)));
+ mapstart = (main_map->l_addr
+ + (ph->p_vaddr & ~(GLRO(dl_pagesize) - 1)));
if (main_map->l_map_start > mapstart)
main_map->l_map_start = mapstart;