advice please? Is there a known issue with SIGINT for scripts?
Denys Vlasenko
vda.linux at googlemail.com
Tue Feb 8 20:38:41 UTC 2011
On Tuesday 08 February 2011 11:23, David Collier wrote:
> here's an edited extract of the svlogd output
>
> 10:12:43.55046 debug do_exit exiting script
> /home/dexdyne/gprs/ping_wan_server.sh with return code 0
> 10:12:43.55059 WAN server [ 78.136.3.89 ] ping check OK
> 10:12:43.55862 WAN OK, and not in failover mode
> 10:12:43.55936 %%%%%%%%%% flag files now are %%%%%%%%%%%%%%%
> 10:12:43.56456 -rw-r--r-- 10:12 /var/wan_wanted_and_available
> 10:12:43.56670 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
> 10:12:43.56728 sleeping for 10 seconds
>
> < I used killall about 4 secs into this sleep >
> < notice the SIGINT is ignored until sleep is over >
This "delayed" trap execution is intended:
http://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html
When a signal for which a trap has been set is received while the shell is waiting for the completion of a utility executing a foreground command, the trap associated with that signal shall not be executed until after the foreground command has completed.
--
vda
More information about the busybox
mailing list