]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
2004-05-18 Andreas Schwab <schwab@suse.de>
authorRoland McGrath <roland@gnu.org>
Tue, 6 Jul 2004 22:59:31 +0000 (22:59 +0000)
committerRoland McGrath <roland@gnu.org>
Tue, 6 Jul 2004 22:59:31 +0000 (22:59 +0000)
* elf/dl-load.c (_dl_map_object_from_fd): Use the end address of
the first segment for mprotect, not l_text_end.

elf/dl-load.c

index f85ae586a1628efea5fc4962da70c97ce5f848de..afbb06b9e57c61a422f57864e1eca32bfcc197a9 100644 (file)
@@ -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);