Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 27 Feb 2001 22:24:54 +0100
From:      Maxime Henrion <mux@qualys.com>
To:        hackers@freebsd.org
Cc:        Tony Finch <dot@dotat.at>
Subject:   Re: [hackers] Re: Setting memory allocators for library functions.
Message-ID:  <20010227222454.G345@nebula.cybercable.fr>
In-Reply-To: <20010227211215.M609@hand.dotat.at>; from dot@dotat.at on Tue, Feb 27, 2001 at 09:12:15PM %2B0000
References:  <20010227202234.K609@hand.dotat.at> <200102272044.f1RKi0n13690@chopper.Poohsticks.ORG> <20010227211215.M609@hand.dotat.at>

next in thread | previous in thread | raw e-mail | index | archive | help
Tony Finch wrote:
> Drew Eckhardt <drew@PoohSticks.ORG> wrote:
> >In message <20010227202234.K609@hand.dotat.at>, dot@dotat.at writes:
> >>In most cases it is impossible to declare the data read-only because
> >>it originally had to be read-write and you can't change its attributes
> >>later. 
> >
> >mprotect(2).
> 
> If it's available at all, mprotect() is often limited to memory
> obtained with mmap(), i.e. not malloc(). Not great for portability.
FreeBSD malloc() calls mmap() as AFAIK many (if not all) malloc()
implementations.

Maxime
-- 
Don't be fooled by cheap finnish imitations ; BSD is the One True Code
Key fingerprint = F9B6 1D5A 4963 331C 88FC  CA6A AB50 1EF2 8CBE 99D6
Public Key : http://www.epita.fr/~henrio_m/

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




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