in reply to Re: forking and monitoring processes
in thread forking and monitoring processes

Hello,

Could you please tell me what @ARGV = <$dir/*> does?

I actually want to execute a command ... shd I use backticks instead to capture the output?

so @output = `Start_Process.exe param1 param2`;

Then parse through each line of @output to see if I find the error messages I am looking for and then close out all the other forks immediately using close ARGV?

Thanks.

Replies are listed 'Best First'.
Re^3: forking and monitoring processes
by zentara (Cardinal) on Jan 25, 2005 at 12:18 UTC
    It "globs" all the files in $dir into @ARGV, which is a special array for input. It's advantage over a regular array is that you can go thru it "line-by-line" without having to open and close each file, which you would have to do with a regular array of files. Your @output plan sounds about right, but there are usually a few glitches to work out, so test,test,test. :-)

    I'm not really a human, but I play one on earth. flash japh