Re: sbrk(2) broken

From: Andrey Chernov <ache_at_nagual.pp.ru>
Date: Fri, 4 Jan 2008 15:21:50 +0300
On Wed, Jan 02, 2008 at 10:38:40PM -0800, Jason Evans wrote:
> Poul-Henning noticed today that xchat fails to start if malloc uses sbrk 
> internally.  

Malloc() itself knows about memory amount _really_ in use by a program and 
could check it don't go beyond the limits, but for this it needs run-time 
check via getrlimit() call for each malloc() call (a program can use 
setrlimit() by itself). Traking direct mmap()s and sbrk()s outside of 
malloc() is also needed.

-- 
http://ache.pp.ru/
Received on Fri Jan 04 2008 - 11:21:57 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:24 UTC