Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.
  • IPC::Run [cpan.org] does it by opening a pipe() to sync to the child, fork()ing, and marking it as close on exit with a fcntl(). Here are some snippets glued together from pieces of IPC::Run:

       ( $sync_reader_fd, $self->{SYNC_WRITER_FD} ) = _pipe ;
       $kid->{PID} = fork() ;
       croak "$! during fork" unless defined $kid->{PID} ;

       unless ( $kid->{PID} ) {
          eval {   
             open $s1, ">&=$self->{SYNC_WR