From owner-freebsd-current Sun Apr 11 21: 2:46 1999 Delivered-To: freebsd-current@freebsd.org Received: from apollo.backplane.com (apollo.backplane.com [209.157.86.2]) by hub.freebsd.org (Postfix) with ESMTP id 31B151521B for ; Sun, 11 Apr 1999 21:02:44 -0700 (PDT) (envelope-from dillon@apollo.backplane.com) Received: (from dillon@localhost) by apollo.backplane.com (8.9.3/8.9.1) id VAA15072; Sun, 11 Apr 1999 21:00:24 -0700 (PDT) (envelope-from dillon) Date: Sun, 11 Apr 1999 21:00:24 -0700 (PDT) From: Matthew Dillon Message-Id: <199904120400.VAA15072@apollo.backplane.com> To: Brian Feldman Cc: current@FreeBSD.ORG Subject: Re: swap-related problems References: Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG :> :> I ran your program. malloc() appears to work properly -- returns NULL when :> the datasize limit is reached. In my case, I set the datasize limit :> to 64MB and ran the program. : :Unset the datasize limit. Now what happens? It used to return NULL, now :it gets SIGKILLed. Seriously, about the killing thing, shouldn't we at least :have a timer so two things don't get killed? If you unset the datasize limit and the program does not exceed the maximum system-supported datasize limit, malloc() should not return NULL even if the system is out of swap. I don't know why it apparently did before -- it shouldn't have. I seem to remember that the default datasize limit for the system was upped a few months ago. I don't think malloc() operation has changed. The correct solution is to set a maximum datasize limit. That is what it is there for. I generally unlimit the datasize for root and set it to around 64MB for all other users. -Matt Matthew Dillon To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message