[boulder.pm] redirect stderr?

Walter Pienciak walter at frii.com
Wed Aug 9 12:12:07 CDT 2000


On Wed, 9 Aug 2000, Robert L. Harris wrote:

> I'm doing an:
> 
> open(CMD, "command -debug 2>&1 |");
> while(<CMD>) {
>   chomp;
>   <do some stuff>
>   print OUTPUT "$Modified_\n";
> }
> 
> 
> But apparantly, I'm not getting the standard error output.  How do I
> capture this?
> 
> 
> :wq!
> ---------------------------------------------------------------------------
> Robert L. Harris                |  Micros~1 :  
> Senior System Engineer          |    For when quality, reliability 
>   at RnD Consulting             |      and security just aren't
>                                 \_       that important!
> DISCLAIMER:
>       These are MY OPINIONS ALONE.  I speak for no-one else.
> FYI:
>  perl -e 'print $i=pack(c5,(41*2),sqrt(7056),(unpack(c,H)-2),oct(115),10);'

Hi, Robert,

This syntax looks right, so I can't think of an immediate answer.

Does "command -debug 2>&1" at the command line give you any output?
Does $foo = `command -debug 2>&1` put anything interesting in $foo?

Walter




More information about the Boulder-pm mailing list