use pkill instead of killall to be more portable
authorMichiel van Baak <michiel@vanbaak.info>
Tue, 7 Oct 2008 18:00:48 +0000 (18:00 +0000)
committerMichiel van Baak <michiel@vanbaak.info>
Tue, 7 Oct 2008 18:00:48 +0000 (18:00 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@147266 65c4cc65-6c06-0410-ace0-fbb531ad65f3

contrib/scripts/safe_asterisk
contrib/scripts/safe_asterisk_restart

index 6ff110b..6dfb953 100644 (file)
@@ -184,7 +184,7 @@ run_asterisk()
                sleep $SLEEPSECS
                if [ $KILLALLMPG123 ]
                then
-                       killall -9 mpg123
+                       pkill -9 mpg123
                fi
        done
 }
index 8178314..4403de6 100644 (file)
@@ -101,8 +101,8 @@ done
 
 # doing the dirty work
 [[ $TRY_STOP_NOW_FIRST ]] && docmd "Asking asterisk kindly to shutdown" "$ASTERISK -rx 'stop now'"
-docmd "Sending asterisk processes the TERM signal" "killall -15 $PROCVICTIMS"
-docmd "Sending asterisk processes KILL signal" "killall -9 $PROCVICTIMS"
+docmd "Sending asterisk processes the TERM signal" "pkill -15 $PROCVICTIMS"
+docmd "Sending asterisk processes KILL signal" "pkill -9 $PROCVICTIMS"
 docmd "Starting safe_asterisk" "$SAFE_ASTERISK"
 for i in $PROCVICTIMS
 do