Räuber Hotzenplotz has asked for the wisdom of the Perl Monks concerning the following question:
which I call from main likepackage SomeModule; sub do_something { # ... something's going on ... print STDERR "D'oh! Error!"; }
Is there anything I can do with Tie::Handle or a similar module to intercept messages written to STDERR and direct them to errhandler()?# What can I do here to direct STDERR messages # to errhandler() ? sub errhandler { ... } SomeModule::do_something();
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Catch messages to STDERR
by Zaxo (Archbishop) on May 05, 2004 at 05:37 UTC | |
|
Re: Catch messages to STDERR
by hv (Prior) on May 05, 2004 at 10:54 UTC | |
|
Re: Catch messages to STDERR
by mifflin (Curate) on May 05, 2004 at 06:17 UTC | |
|
Re: Catch messages to STDERR
by raptnor2 (Beadle) on May 05, 2004 at 21:38 UTC | |
|
Re: Catch messages to STDERR
by DrHyde (Prior) on May 06, 2004 at 08:48 UTC |