From owner-freebsd-hackers Sat Feb 24 7:40:46 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from flood.ping.uio.no (flood.ping.uio.no [129.240.78.31]) by hub.freebsd.org (Postfix) with ESMTP id 4A74037B65D for ; Sat, 24 Feb 2001 07:40:43 -0800 (PST) (envelope-from des@ofug.org) Received: (from des@localhost) by flood.ping.uio.no (8.9.3/8.9.3) id QAA55975; Sat, 24 Feb 2001 16:40:34 +0100 (CET) (envelope-from des@ofug.org) X-URL: http://www.ofug.org/~des/ X-Disclaimer: The views expressed in this message do not necessarily coincide with those of any organisation or company with which I am or have been affiliated. To: seebs@plethora.net (Peter Seebach) Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: Setting memory allocators for library functions. References: <200102230627.f1N6Rk618467@guild.plethora.net> From: Dag-Erling Smorgrav Date: 24 Feb 2001 16:40:33 +0100 In-Reply-To: seebs@plethora.net's message of "Fri, 23 Feb 2001 00:27:46 -0600" Message-ID: Lines: 16 User-Agent: Gnus/5.0802 (Gnus v5.8.2) Emacs/20.4 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG seebs@plethora.net (Peter Seebach) writes: > In message <3A95FF54.5D48E0A1@sm.socccd.cc.ca.us>, Farooq Mela writes: > > How do you guys feel about this? > It is a mistake to believe that you "don't have to worry about running > out of memory". You should always check, every time, and exit as gracefully > as you can. This is all academic since FreeBSD does memory overcommit, so unless you run out of address space for your process before you run out of actual memory and/or swap (not likely, but quite possible) malloc() will never return NULL and you won't know a thing until you dirty one page too many and segfault. DES -- Dag-Erling Smorgrav - des@ofug.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message