![]() |
|
good chemistry is complicated, and a little bit messy -LW |
|
PerlMonks |
Re^3: Capturing stderrby 0xbeef (Hermit) |
on Dec 31, 2005 at 01:08 UTC ( #520092=note: print w/replies, xml ) | Need Help?? |
I once asked a similar question in Redirecting stdout/stderr to pipe. Thelonius described a method in (Re: Redirecting stdout/stderr to pipe) that captures stdout as well as stderr (seperately) to array references (see the @$outref and @$errref portions of the code). The code also includes detection of commands that have been running for too long or when the array's output size exceeds $g_maxlines lines. 0xbeef
In Section
Seekers of Perl Wisdom
|
|