Subject: Re: Replacement for grep(1) (part 2)
To: Jon Ribbens <jon@oaktree.co.uk>
From: Dag-Erling Smorgrav <des@flood.ping.uio.no>
List: tech-userlevel
Date: 07/12/1999 03:46:59
Jon Ribbens <jon@oaktree.co.uk> writes:
> "Daniel C. Sobral" <dcs@newsguy.com> wrote:
> > OTOH, though, FreeBSD's malloc() is very unlikely to return an out
> > of memory error.
> Why is that?

Because FreeBSD overcommits memory. You can allocate (almost) as much
memory as you want regardless of how much RAM / swap you have. You
won't run into trouble unless you actually try to use too much of it.

> What happens if the process hits its resource limits?

Malloc() fails with ENOMEM.

DES
-- 
Dag-Erling Smorgrav - des@flood.ping.uio.no