From owner-freebsd-hackers Sun Sep 21 09:21:37 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id JAA06110 for hackers-outgoing; Sun, 21 Sep 1997 09:21:37 -0700 (PDT) Received: from bitbox.follo.net (bitbox.follo.net [194.198.43.36]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id JAA06103 for ; Sun, 21 Sep 1997 09:21:31 -0700 (PDT) Received: (from eivind@localhost) by bitbox.follo.net (8.8.6/8.8.6) id SAA20155; Sun, 21 Sep 1997 18:18:23 +0200 (MET DST) Date: Sun, 21 Sep 1997 18:18:23 +0200 (MET DST) Message-Id: <199709211618.SAA20155@bitbox.follo.net> From: Eivind Eklund To: Poul-Henning Kamp CC: gram@cdsec.com, hackers@FreeBSD.ORG In-reply-to: Poul-Henning Kamp's message of Thu, 18 Sep 1997 20:51:13 +0200 Subject: Re: Bug in malloc/free (was: Memory leak in getservbyXXX?) References: <199709181811.MAA13376@rocky.mt.sri.com> <10897.874608673@critter.freebsd.dk> Sender: owner-freebsd-hackers@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk > > In message <199709181811.MAA13376@rocky.mt.sri.com>, Nate Williams writes: > >Poul-Henning Kamp writes: > No, all you have to do is to make each allocation have it's own set of > pages, munmap them when free is called and never use those pages again. > > You run out of address space really fast, and it is slow, but it works. efence does this, if you use the correct option. I produced an URL in an earlier message in this thread. BTW: Would it be an idea to add some form of optional loop checking (or possibly even a full invariant) to phkmalloc, if it isn't there already? Both double-linked and single-linked lists are trivial to check for loops, at least. Eivind.