#!/usr/bin/perl $SIG{CHLD}=sub { wait(); print "Child exited\n";}; $| = 1; while(1) { if ((my $f = fork()) == 0) { # Child sleep(1); exit(0); } else { print "Started child $f\n"; } sleep(2); }
In reply to Re: Reaping Zombies (dont wanna wait)
by sgifford
in thread Reaping Zombies (dont wanna wait)
by seaver
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |