I'm having a problem with overriding a sub in CORE::GLOBAL. I need to override exit(), and I'm doing that with:
BEGIN { *CORE::GLOBAL::exit = sub { print "exit: ".shift; } };
..which works for the program itself.
However! When I call exit() in a module used by my program, the module actaully calls 'exit()' in its original meaning, and NOT the one I defined myself.
How do I get the module to treat exit() the way I defined it?
I don't wanna change code in the module itself.
Thanks in advance!
-- Jesper Nøhr - decius <[EMAIL PROTECTED]> Holstebro, Denmark -- http://printf.dk UNIX Administrator, Software Engineer, Geek.
-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>