tobold.org

correct • elegant • free

△ comp.lang.perl △

◅ deleting a record in a dbm database

split into word and the rest of string ▻

Redirecting STDERR to STDOUT

In article <30BB3824.F6B@soltech.com>, Derald H McMillan III
<derald@soltech.com> wrote:
>I have a need to redirect STDERR to STDOUT in a perl program.

    open(STDERR, ">& STDOUT") or die "$0: can't dup stdout: $!\n";

>Any hints on how to do this.

RTFM: it's in the perlfunc man page under the description of the
open function.

Tim.
--
Tim Goodwin   | "After all, what did Brunel, Watt, Boulton and
Unipalm PIPEX | Telford do that was complex?  I could have built
Cambridge, UK | the Great Western Railway on my own." -- Ian Batten

Original headers:

From: tim@pipex.net (Tim Goodwin)
Newsgroups: comp.lang.perl.misc
Subject: Re: Redirecting STDERR to STDOUT
Date: 28 Nov 1995 17:36:30 GMT
Organization: Unipalm PIPEX
Message-ID: <49fhau$hoi@wave.news.pipex.net>
References: <30BB3824.F6B@soltech.com>

△ comp.lang.perl △

◅ deleting a record in a dbm database

split into word and the rest of string ▻