path: root/crt/crt1.c
diff options
authorRich Felker <>2012-12-07 22:33:11 -0500
committerRich Felker <>2012-12-07 22:33:11 -0500
commitb8ccf8e46bab6ee9d63a6e392c3b33b9aa89255c (patch)
tree5507553d3354f4650d904df2e54829cf1b38181c /crt/crt1.c
parent3ee67505fe50299d6df6e9bca894fd6b568669fb (diff)
page-align initial brk value used by malloc in shared libc
this change fixes an obscure issue with some nonstandard kernels, where the initial brk syscall returns a pointer just past the end of bss rather than the beginning of a new page. in that case, the dynamic linker has already reclaimed the space between the end of bss and the page end for use by malloc, and memory corruption (allocating the same memory twice) will occur when malloc again claims it on the first call to brk.
Diffstat (limited to 'crt/crt1.c')
0 files changed, 0 insertions, 0 deletions