Re: while (wait(&status) != pid) and waitpid (pid, &status, 0)
From: Alex Vinokur (alexvn_at_x-privat.org)
Date: 11/26/05
- Next message: Bjørn Augestad: "Re: strange problem with MySQL"
- Previous message: Paul Pluzhnikov: "Re: while (wait(&status) != pid) and waitpid (pid, &status, 0)"
- In reply to: Paul Pluzhnikov: "Re: while (wait(&status) != pid) and waitpid (pid, &status, 0)"
- Next in thread: Paul Pluzhnikov: "Re: while (wait(&status) != pid) and waitpid (pid, &status, 0)"
- Reply: Paul Pluzhnikov: "Re: while (wait(&status) != pid) and waitpid (pid, &status, 0)"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 26 Nov 2005 17:21:14 +0100
"Paul Pluzhnikov" <ppluzhnikov-nsp@charter.net> wrote in message news:m3d5knpcf2.fsf@somewhere.in.california.localhost...
> "Alex Vinokur" <alexvn@x-privat.org> writes:
>
> > Are 'while (wait(&status) != pid)' and 'waitpid (pid, &status, 0)' have the same behavior?
>
> No.
>
> The first one will collect any child processes that have exit()ed;
> the second will wait only for the specified process.
>
[snip]
'wait(&status)' collects any child processes that have exit()ed
Also 'while (wait(&status) != pid)' ?
--
Alex Vinokur
email: alex DOT vinokur AT gmail DOT com
http://mathforum.org/library/view/10978.html
http://sourceforge.net/users/alexvn
- Next message: Bjørn Augestad: "Re: strange problem with MySQL"
- Previous message: Paul Pluzhnikov: "Re: while (wait(&status) != pid) and waitpid (pid, &status, 0)"
- In reply to: Paul Pluzhnikov: "Re: while (wait(&status) != pid) and waitpid (pid, &status, 0)"
- Next in thread: Paul Pluzhnikov: "Re: while (wait(&status) != pid) and waitpid (pid, &status, 0)"
- Reply: Paul Pluzhnikov: "Re: while (wait(&status) != pid) and waitpid (pid, &status, 0)"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|