diff options
| author | Matthias P. Braendli <matthias.braendli@mpb.li> | 2015-09-10 16:32:35 +0200 | 
|---|---|---|
| committer | Matthias P. Braendli <matthias.braendli@mpb.li> | 2015-09-10 16:33:49 +0200 | 
| commit | 46328eb05aef3a07c48ea0ec094bb887ed2c6e46 (patch) | |
| tree | 791dad5060dd84e9ca10241476738f5af13448c3 | |
| parent | 79a58e5b66c76044ed083265c90b853cb4924da8 (diff) | |
| download | dab-scripts-46328eb05aef3a07c48ea0ec094bb887ed2c6e46.tar.gz dab-scripts-46328eb05aef3a07c48ea0ec094bb887ed2c6e46.tar.bz2 dab-scripts-46328eb05aef3a07c48ea0ec094bb887ed2c6e46.zip | |
Send SIGINT to scripts on Ctrl-C
| -rwxr-xr-x | radio.sh | 5 | 
1 files changed, 3 insertions, 2 deletions
| @@ -16,9 +16,10 @@ printmsg() {  script_pid=0  sigint_trap() { -    printerr "Got Ctrl-C, killing radio encoder script" +    printerr "Got Ctrl-C"      if [[ "$script_pid" != "0" ]] ; then -        kill $script_pid +        printmsg "killing radio encoder script $script_pid" +        kill -INT $script_pid          script_pid=0          wait      fi | 
