in reply to script hangs after executing program

I'm not certain I can help with the specific problem without knowing more about $prog. However, I wonder if when you say you tried open, you meant to say exec instead, because open and system are not similar system and exec are similar.

Updated: monkey_boy points out below how system and open can indeed be similar, but without knowing what $prog is doing I don't know that it can be assumed to be so in this case. However, I updated the text above to say what I mean more clearly.

My apologies to open, I meant no disrespect.

  • Comment on Re: script hangs after executing program

Replies are listed 'Best First'.
Re^2: script hangs after executing program
by monkey_boy (Priest) on Dec 15, 2006 at 17:13 UTC
    open and system can be very similar.. what happens when you do this:
    open ( my $fh , "ps -elf |"); print $_ while(<$fh>);



    This is not a Signature...