I think in principle though sleep is not the right primitive. You want a wait-on-event with an additional timeout. In Win32, I'd use an Event Flag for this. I'm sure any modern OS has a selection of mechanisms like this to choose from.
How to do it portably in Perl? How about a socket? Sleeper does a blocking read on a socket, and signaler writes a byte to signal.
—John
In reply to Re: Awake from sleep()
by John M. Dlugosz
in thread Awake from sleep()
by cmilfo
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |