You may want to check out Automatic stack tracebacks in warnings? on how I replace a warn handler and place a new warn handler in the "stack" by calling the old warn handler during my warn handler. It's one of the few times where using & to call a function is the right WTDI since I want to transparently pass along all parameters. Now that I'm looking at it, the if modifier probably should also be checking that $oldwarn is a CODE ref...
As for it being temporary - dragonchild's local suggestion is bang on. He just missed the part where you wanted to call the previous warn subroutine from within your own.
In reply to Re: signal handlers that play nice
by Tanktalus
in thread signal handlers that play nice
by esharris
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |