in reply to win32, ctrl-c, sleep, and signals
This is caused by the 'safe signals' that were introduced by 5.8.0. The sleep is treated a single opcode and so the signal is not seen until after the opcode completes. See the 'safe signals' section of perl58delta. Also see perl581delta for how to bypass this and get the old unsafe behaviour back.
c:\test>set PERL_SIGNALS=unsafe c:\test>p1 [0] Perl> $SIG{ INT } = sub{ print 'Caught signal INT'; };; [0] Perl> print 'still here' while sleep 10;; still here Caught signal INT still here Terminating on signal SIGBREAK(21)
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: win32, ctrl-c, sleep, and signals
by SirBones (Friar) on May 30, 2006 at 16:38 UTC | |
by BrowserUk (Patriarch) on May 30, 2006 at 17:11 UTC | |
Re^2: win32, ctrl-c, sleep, and signals
by sgifford (Prior) on May 30, 2006 at 16:40 UTC | |
by BrowserUk (Patriarch) on May 30, 2006 at 17:12 UTC |