cons-discuss
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Cons output on NT


From: Zachary Deretsky
Subject: Cons output on NT
Date: Mon, 2 Oct 2000 14:17:37 -0700

> cons.pl -- -debug 2> cons.log
does not work for me.
I suspect it has something to do with Perl and DOS notions of STDOUT and
STDERR filehandles.
I use 'perl version 5.005_03 built for MSWin32-x86'
built from sources.


I achieved redirection into a log file by putting this into my Construct:

$G_logfile = 'cons_log.txt';
open(LOG, ">$G_logfile") || die "Can't open $G_logfile";
$B_oldFh = select(LOG); $| = 1; select($B_oldFh);
open(STDOUT, ">&LOG") || die "Can't redirect stdout to $G_logfile";
open(STDERR, ">&LOG") || die "Can't redirect stderr to $G_logfile";

I prefer to both see the output and get the logfile.

Any alternative solutions?

Zach,




reply via email to

[Prev in Thread] Current Thread [Next in Thread]