I have a small script that goes to sleep for several minutes. I trap SIGINT so that I can do a graceful shutdown of the script. The problem is, if a SIGINT is sent to the script during sleep, the script won't see it until it wakes back up.
Is there a way to wake up the script when a signal is sent to it?
Update: Yes, I should have confessed I was on windows. I rarely use signals, and I rarely use windows. I forgot that it isn't the best combination. Thanks!
Thanks,
Ted Young
($$<<$$=>$$<=>$$<=$$>>$$) always returns 1. :-)In reply to sleep and waking on signal handlers by TedYoung
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |