[boulder.pm] unblocked pipes

Rob Nagler nagler at bivio.com
Wed Aug 2 17:45:20 CDT 2000


Amar Vattakandy wrote:
>  | before I read the pipe ?

http://www.perl.com/pub/doc/manual/html/pod/perlipc.html

Look at "select".  It allows you to "poll" the pipe.  I wouldn't
recommend polling.  You might rather consider two processes:
one for reading and one for writing.  Really depends on the
application, though.

It might be problematic to use:

$readline = <CHILD>;

This assumes that a newline is returned.  If a newline isn't returned
even if select returns true, the <CHILD> call won't return.

Rob



More information about the Boulder-pm mailing list