[BusyBox] Re: [patch] Why busybox xargs is broken.

Vladimir N. Oleynik dzo at simtreas.ru
Fri Oct 3 11:15:50 UTC 2003


> On Fri Oct 03, 2003 at 01:39:12PM +0400, Vladimir N. Oleynik wrote:
>>>>+			waitpid(p,&retval,0);
>>>I recommend using just wait(&retval) 
>>>>+			return retval>>8;
>>I do not understand, what for to change this my piece of a code.
>>I for a long time have noticed, that many do not understand
>>as vfork() function works and try to get rid of it. :-(
> The problem is on some Linux architectures (such as powerpc)

Strange... I think, vfork() more primitive for realisation vs fork().
For example, for nonMMU systems.

> vfork does not work or is not implemented at all (for example
> with all 2.0.x kernels).  

But, we don`t support kernel 2.0 now ;-)

> In glibc (and in uClibc to try and
> match glibc behavior) for these architectures, vfork() is
> implemented with just a call to fork() and there is not even a
> call to wait() in the fake vfork implementation...
> So unfortunately, we can not really rely on the vfork semantics
> -- sometimes the parent process will not actually be blocked
> until the child exits.  So adding the extra call to wait() is a
> good idea to avoid wierd sequencing problems.

But my code have wait() calling...


More information about the busybox mailing list