Actually, wait will return when one of the child processes exits, but it will "wait" (in some sense) on all of them.
In other words, if you call wait and you have child processes that are executing, it will block. It will return when any one of them (or several if they happen to exit simultaneously) exits. If you fork off multiple children, and you want to block until all of them exit, just put wait in a loop: 1 while wait() > 0; More information at perlfunc:wait and wait.
HTH
In reply to Re: help using the wait() command
by VSarkiss
in thread help using the wait() command
by Ras
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |