Removed a ignore shellcheck comment in zzz_evobackup and fix warning

Since only one PID can be in the PID file, we will never have more than one, we can thus easily quote the variable and remove the shellcheck ignore.
This commit is contained in:
Patrick Marchand 2020-04-20 12:12:51 -04:00
parent d2b6094f7f
commit ec994f7e2c
1 changed files with 1 additions and 3 deletions

View File

@ -123,9 +123,7 @@ pick_server() {
if [ -e "${PIDFILE}" ]; then
pid=$(cat "${PIDFILE}")
# Does process still exist ?
# ignore check because multiple processes might exist
# shellcheck disable=SC2086
if kill -0 ${pid} 2> /dev/null; then
if kill -0 "${pid}" 2> /dev/null; then
# Killing the childs of evobackup.
for ppid in $(pgrep -P "${pid}"); do
kill -9 "${ppid}";