Help for this page

Select Code to Download


  1. or download this
    sub fork_test {
        my ($file,$logfile)= @_;
    ...
        sleep 3;
        print "I'm done working.\n";
    }
    
  2. or download this
    while ( $count > $max ) {
        wait;
        $count--;
    }
    
  3. or download this
    die "Can't fork: $!\n" unless defined(my $pid = fork());