eval { local $SIG{ALRM} = sub { die "alarm\n" }; # NB: \n required alarm 2; `dir /s c:`; alarm 0; };
Surely alarm should interrupt the timeconsuming `dir /s c:` (recursive dir) after 2 seconds?
In reply to Re^3: simple timeout
by disciple01
in thread simple timeout
by disciple01
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |