in reply to Timeouts/timers on Win32 system

Have you tried the alarm SECONDS function (In an eval block) - it's usage as a timeout timer is described in perlfunc.

"We are enthusiastically pro-laugh, we are pro-choice as well. We respect each and every individualÂÂs right not to laugh. If you want to be miserable, go right ahead. Whatever makes you happy."

Replies are listed 'Best First'.
Re: Re: Timeouts/timers on Win32 system
by PodMaster (Abbot) on Dec 08, 2003 at 15:11 UTC
    Hello, just a fyi
    E:\>perldoc perlport|grep alarm alarm SECONDS alarm Not implemented. (Win32) E:\>perl -le"alarm 0" The Unsupported function alarm function is unimplemented at -e line 1.
    update: apparently, for perl 5.8.x this has changed, but perlport wasn't updated (i'll notify perl5-porters if perl-current is not up to date)
    E:\>perl local $SIG{ALRM} = sub { die "alarm!!!!" }; alarm 1; sleep 10; alarm 0; __END__ alarm!!!! at - line 1.

    MJD says "you can't just make shit up and expect the computer to know what you mean, retardo!"
    I run a Win32 PPM repository for perl 5.6.x and 5.8.x -- I take requests (README).
    ** The third rule of perl club is a statement of fact: pod is sexy.