Help for this page

Select Code to Download


  1. or download this
    use IPC::Open3;
    
    ...
       waitpid($pid, 0);
       print "after waitpid\n";
    }
    
  2. or download this
    3297
    loop 1
    ...
    Status is: sleep 11
    Status is: sleep 11
    Status is: sleep 11
    
  3. or download this
       print "Status is: $status\n";
    
  4. or download this
    sub default { print "got SIG ".shift()."\n"}
    $SIG{$_} = \&default for keys %SIG;
    $SIG{USR1} = \&status;
    
  5. or download this
    #!/usr/bin/perl
    # have to print to a terminal directly,
    ...
    $SIG{$_} = \&default for keys %SIG;
    
    sleep $_ for 1..shift;
    
  6. or download this
    3437
    loop 1
    ...
    after waitpid
    loop 2
    ...