in reply to Re: Killing a shell script from within a perl script
in thread Killing a shell script from within a perl script
I tried doing this:
It turns out that the shell script is not even executed.eval { local $SIG{ALRM}=sub{die "alarm\n"}; alarm 600; $shell_out = system("./sh1.sh"); alarm 0; }; if($@) { die unless $@ eq "alarm\n"; }
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^3: Killing a shell script from within a perl script
by almut (Canon) on Mar 03, 2010 at 18:49 UTC | |
by strider88 (Initiate) on Mar 09, 2010 at 21:58 UTC |