Subject: Re: popen reentrant (was Re: SA/pthread and vfork)
To: David Laight <david@l8s.co.uk>
From: Bill Studenmund <wrstuden@netbsd.org>
List: tech-kern
Date: 09/11/2003 09:53:06
On Thu, 11 Sep 2003, David Laight wrote:

> > The sharing of address space is an
> > optimization, not a communications mechanism.  Any applications that
> > breaks is broken and needs to be fixed.
>
> Are you going to 'fix' sh then?

Uhm, I thought our sh doesn't use vfork() because it has issues.

> I don't think you can assume that calls to vfork() can be silently replaced
> by fork().

As I recall, for a long time our vfork() really was fork(), so I don't
think you're correct with that. Other than the fact that doing the switch
would let the parent in principle see the child before it exec's, you
should be able to make the switch.

Take care,

Bill