On Mon, Jul 13, 2009 at 22:57, Jenn G. wrote:
> Hello,
>
> From the code below:
>
> eval {
> local $SIG{ALRM} = sub { die "TIMEOUT\n" };
> alarm($seconds);
> ... code to execute with timeout here ...
> alarm(0); # cancel alarm (if code ran fast)
> };
> alarm(0); # cancel alarm (i
Hello,
>From the code below:
eval {
local $SIG{ALRM} = sub { die "TIMEOUT\n" };
alarm($seconds);
... code to execute with timeout here ...
alarm(0); # cancel alarm (if code ran fast)
};
alarm(0);# cancel alarm (if eval failed)
Is the second alarm(0) needed or not?
In
2009/7/11 Steve Bertrand :
> I have numerous methods such as the following. They all perform the same
> basic function based on the parameter passed in ($name, $key or nothing).
>
> I've recently moved out the actual data definition (hash) into a
> different 'private' function in order to make thin