in reply to Re: how to send both STDOUT and STERR to the same file
in thread how to send both STDOUT and STERR to the same file
use strict; use warnings; use IO::Handle; my $file = 'C:\Progra~1\Ethereal\output.dat'; open (STDERR, ">&STDOUT"); open (OUTPUT, ">$file") || die $!; STDOUT->fdopen(\*OUTPUT, "w") || die $!; print "This is STDOUT\n"; warn "This is a warning\n";
|
|---|