home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.perl
- Path: sparky!uunet!europa.asd.contel.com!darwin.sura.net!wupost!gumby!destroyer!ubc-cs!unixg.ubc.ca!news
- From: andy@orchid.bdc.ubc.ca (Andrew Dwelly)
- Subject: STDOUT & STDERR
- Message-ID: <1992Sep14.224832.21737@unixg.ubc.ca>
- Sender: news@unixg.ubc.ca (Usenet News Maintenance)
- Nntp-Posting-Host: orchid.bdc.ubc.ca
- Organization: University of British Columbia, Vancouver, B.C., Canada
- Date: Mon, 14 Sep 1992 22:48:32 GMT
- Lines: 18
-
-
- Another beginners question. Whats the idiom in perl for starting
- a sub process with a filehandle, and getting both the STDOUT and
- the STDERR of that process for subsequent parsing ??
-
- I suppose what I have in mind is something like :-
-
- open (CHILD, "child_process 2>&1 |"); # I don't think this works!
- while (<CHILD>)
- {
- do_something_with_child_here;
- }
-
- that is, to be able to read the child's STDOUT, and STDERR in order
- to see when something horrid has happened to child_process.
-
- Andy (andy@bcu.ubc.ca)
-
-