From: Roland McGrath Date: Tue, 6 Jul 2004 22:59:31 +0000 (+0000) Subject: 2004-05-18 Andreas Schwab X-Git-Tag: cvs/fedora-base~343 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=3fb035f6a242b95261c94376f2c4d770f36e4eed;p=thirdparty%2Fglibc.git 2004-05-18 Andreas Schwab * elf/dl-load.c (_dl_map_object_from_fd): Use the end address of the first segment for mprotect, not l_text_end. --- diff --git a/elf/dl-load.c b/elf/dl-load.c index f85ae586a16..afbb06b9e57 100644 --- a/elf/dl-load.c +++ b/elf/dl-load.c @@ -1117,7 +1117,7 @@ cannot allocate TLS data structures for initial thread"); unallocated. Then jump into the normal segment-mapping loop to handle the portion of the segment past the end of the file mapping. */ - __mprotect ((caddr_t) l->l_text_end, + __mprotect ((caddr_t) (l->l_addr + c->mapend), loadcmds[nloadcmds - 1].allocend - c->mapend, PROT_NONE);