summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorCase Duckworth2022-06-29 14:27:44 -0500
committerCase Duckworth2022-06-29 14:27:44 -0500
commit4b25e38f78d02050e515fa7cbe82f8d26a2de017 (patch)
treeb7346e5da49e20c75b8943d5d28f4d0bcf465b26
parentAdd radio.stations (diff)
downloadradio-4b25e38f78d02050e515fa7cbe82f8d26a2de017.tar.gz
radio-4b25e38f78d02050e515fa7cbe82f8d26a2de017.zip
Loop the kill to ensure death
-rwxr-xr-xradio8
1 files changed, 7 insertions, 1 deletions
diff --git a/radio b/radio index dc1297a..d0c12a6 100755 --- a/radio +++ b/radio
@@ -60,10 +60,16 @@ _radio_play() {
60} 60}
61 61
62_radio_kill() { 62_radio_kill() {
63 if ! xargs -a "$RADIO_PID_FILE" kill; then 63 if ! [ -f "$RADIO_PID_FILE" ]; then
64 echo >&2 "I don't think radio is running." 64 echo >&2 "I don't think radio is running."
65 exit 1 65 exit 1
66 fi 66 fi
67 printf >&2 '%s' "Killing radio"
68 while xargs -a "$RADIO_PID_FILE" kill 2>/dev/null; do
69 printf '.'
70 done
71 rm "$RADIO_PID_FILE"
72 echo
67 exit 73 exit
68} 74}
69 75