Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re^2: finding the status of the program being called from perl

by roseberry123 (Acolyte)
on Jun 10, 2004 at 07:28 UTC ( #363005=note: print w/ replies, xml ) Need Help??


in reply to Re: finding the status of the program being called from perl
in thread finding the status of the program being called from perl

thanks. i think this is what i am looking for. but i'm getting really confused. besides perldoc.com, do you know where i can find more information about whether i should choose $sel->can_read or $sel->can_write? i think my perl script is becoming really confused, because what used to work is now not working anymore. and also, if i am using open2(*Reader, *Writer, $cmd), which filehandle, Reader or Writer, should i use to find out whether the interactive program is waiting for input? or do i use STDIN?

thanks very much. i really appreciate it.


Comment on Re^2: finding the status of the program being called from perl
Select or Download Code
Re^3: finding the status of the program being called from perl
by matija (Priest) on Jun 10, 2004 at 07:40 UTC
    You should choose $sel->can_read for the file handle you are reading from (i.e. the filehandle that the other process is writing to).

    The filehandle you should test to see if the other program is waiting to read is the filehandle you write to.

      matija, thank you.

      but it's not working. i think it's more complicated than it sounds? i mean, using IO::Select. are we supposed to go into a while loop? too confusing.

      but not all hopeless, i think i found another solution. i think i will try bioperl.

      anything you want to do, if you search long enough, you will find someone else has already done it.

      thanks anyway. take care. see you.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://363005]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (10)
As of 2014-07-28 11:47 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (196 votes), past polls