We don't bite newbies here... much | |
PerlMonks |
Re: How do I trap $SIG{INT} ( sigint aka Ctrl^c )?by Anonymous Monk |
on Feb 26, 2003 at 16:00 UTC ( [id://238807]=note: print w/replies, xml ) | Need Help?? |
Instead of killing yourself, as suggested by crazyinsomniac, you could also try just exiting. This avoids the shell's response of 'aborted' when the program is killed. I.e.: sub myhand { print "\n caught $SIG{INT}",@_,"\n"; exit(0); } -Josh O-
In Section
Seekers of Perl Wisdom
|
|