Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: Cleaner redirection of STDERR

by RhetTbull (Curate)
on Sep 24, 2001 at 07:58 UTC ( #114243=note: print w/ replies, xml ) Need Help??


in reply to Cleaner redirection of STDERR

You may want to take a look at the Filter::Handle module. Instead of using a separate subroutine to write to your logfile or STDERR you could simply use 'print STDERR "my message";' and let Filter::Handle do what you meant. Take a look at my node about Filter::Handle for an example. Regards,
-RT


Comment on Re: Cleaner redirection of STDERR
Replies are listed 'Best First'.
Re (tilly) 2: Cleaner redirection of STDERR
by tilly (Archbishop) on Sep 24, 2001 at 08:33 UTC
    Did you know that Filter::Handle was written by our own btrott?

    Note that, as always, tie is not friends with any C-level stuff (eg modules, system calls) that don't go through Perl's IO layer, and tie doesn't like local very much. Both of those are gotchas I like to warn people about since I have been bitten by them in the past.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://114243]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (14)
As of 2015-07-28 11:58 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (254 votes), past polls