Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
However, while the code above does execute, so I know the signal's been caught, the script still dies anyway. I also tried placing the code that uses the modules in an eval(), based on something else I read, but I get the same result. What can I do to keep my script running even when a module it uses wants to die? Thanks in advance, and sorry if I am missing an obvious answer (or am otherwise doing something obviously wrong). James$SIG{__DIE__} = sub { if (!ref($_[0])) { $err = join('', @_); } print "error $err\n"; };
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: How do I avoid a die generated by a module?
by broquaint (Abbot) on Jun 06, 2003 at 17:05 UTC | |
by Anonymous Monk on Jun 06, 2003 at 17:29 UTC | |
by bbfu (Curate) on Jun 06, 2003 at 17:46 UTC | |
|
Re: How do I avoid a die generated by a module?
by PodMaster (Abbot) on Jun 07, 2003 at 07:21 UTC |