Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 23 Aug 2001 10:38:31 -0700 (PDT)
From:      Matt Dillon <dillon@earth.backplane.com>
To:        Julian Elischer <julian@elischer.org>
Cc:        Alfred Perlstein <bright@mu.org>, Bernd Walter <ticso@mail.cicely.de>, freebsd-hackers@freebsd.org
Subject:   Re: mmap MAP_INHERIT question.
Message-ID:  <200108231738.f7NHcVo87785@earth.backplane.com>
References:   <Pine.BSF.4.21.0108231012330.48732-100000@InterJet.elischer.org>

next in thread | previous in thread | raw e-mail | index | archive | help
   MAP_INHERIT is broken and always has been.

					-Matt

:exec gives you an new vm space..
:inherrit only applies to forks
:
:
:On Thu, 23 Aug 2001, Alfred Perlstein wrote:
:
:> * Bernd Walter <ticso@mail.cicely.de> [010823 06:16] wrote:
:> > I do the following:
:> >         buf = (char*)mmap(NULL, BUFSIZE, PROT_READ | PROT_WRITE,
:> > 	    MAP_ANON | MAP_INHERIT | MAP_SHARED, -1, 0);
:> > 
:> > Now I vfork/execve a child.
:> > But the child can't access the mmaped memory.
:> > It was my understanding that MAP_INHERIT | MAP_SHARED keep the memory
:> > over the execve.
:> 
:> Without sample code this is impossible to explain.
:> 
:> -- 
:> -Alfred Perlstein [alfred@freebsd.org]
:> Ok, who wrote this damn function called '??'?
:> And why do my programs keep crashing in it?
:> 
:> To Unsubscribe: send mail to majordomo@FreeBSD.org
:> with "unsubscribe freebsd-hackers" in the body of the message
:> 
:
:
:To Unsubscribe: send mail to majordomo@FreeBSD.org
:with "unsubscribe freebsd-hackers" in the body of the message
:


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?200108231738.f7NHcVo87785>