You can pair this with the original code I posted, substituting insistent_fork for fork. (Works on OS X.)sub insistent_fork { my $pid = undef; FORK: { if (defined ($pid = fork())) { return $pid; } elsif ($! =~ /No more process/) { sleep 5; redo FORK; } else { die "Can't fork: $!\n"; } } }
In reply to Re: Re: Re: Reaping Zombies (dont wanna wait)
by pemungkah
in thread Reaping Zombies (dont wanna wait)
by seaver
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |