Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 8 Jan 2008 00:06:33 +0000
From:      "Igor Mozolevsky" <igor@hybrid-lab.co.uk>
To:        "Andrew Reilly" <andrew-freebsd@areilly.bpc-users.org>
Cc:        Kostik Belousov <kostikbel@gmail.com>, Peter Jeremy <peterjeremy@optushome.com.au>, Poul-Henning Kamp <phk@phk.freebsd.dk>, freebsd-current@freebsd.org
Subject:   Re: sbrk(2) broken
Message-ID:  <a2b6592c0801071606g4c0dcb9ap117e345fda5e7e5f@mail.gmail.com>
In-Reply-To: <20080108101942.05471233@duncan.reilly.home>
References:  <a2b6592c0801070515g37735475kc0922af8f93723ca@mail.gmail.com> <10319.1199711927@critter.freebsd.dk> <20080108101942.05471233@duncan.reilly.home>

next in thread | previous in thread | raw e-mail | index | archive | help
On 07/01/2008, Andrew Reilly <andrew-freebsd@areilly.bpc-users.org> wrote:
> On Mon, 07 Jan 2008 13:18:47 +0000
> "Poul-Henning Kamp" <phk@phk.freebsd.dk> wrote:
>
> > Yes, but you will not see this complication, it will be hidden
> > in the implementation of malloc(3).
>
> How could you hide it inside malloc?  Would malloc start
> returning 0 after receiving the "less mem than desirable"
> signal?  Would it ever go back to returning non-zero?

I'm with Andrew on this one. The only (sensible) way I could see it
being hidden behind malloc() is if malloc() blocks until sufficient
memory becomes available.

I thought the real idea behind SIGDANGER was to tell the kernel "I
kind of know what I'm doing, so if you gonna kill something don't kill
me" and that was achieved by AIX not SIGKILLing processes that had
sigaction(SIGDANGER) != SIG_IGN.

Igor :-)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?a2b6592c0801071606g4c0dcb9ap117e345fda5e7e5f>