On Wednesday 27 March 2002 00:13, kevin lyda wrote:
> the reserve suggestion wouldn't lead to a greater chance for leaks as
> it's just a hint to malloc's internals as to how much memory is about to
> be reserved. it could even be more efficient as it can lead to just one
> sbrk call instead of several (which is also why some programs actually
> fire off one large malloc and manage the pool themselves).
But would the "reserve" call actually allocate the memory? If not, you'll
still have to check the return from every malloc, and do all the messy
stuff with free!
Maintained by the ILUG website team. The aim of Linux.ie is to
support and help commercial and private users of Linux in Ireland. You can
display ILUG news in your own webpages, read backend
information to find out how. Networking services kindly provided by HEAnet, server kindly donated by
Dell. Linux is a trademark of Linus Torvalds,
used with permission. No penguins were harmed in the production or maintenance
of this highly praised website. Looking for the
Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!