bkctld-stop: pkill outside of conditional

it breaks the stop action
This commit is contained in:
Jérémy Lecour 2020-04-03 00:37:43 +02:00 committed by Jérémy Lecour
parent c920e91304
commit 88dd2e448b

View file

@ -19,7 +19,9 @@ test -d "${jail_path}" || error "${jail_name}: jail is missing."
pid=$(cat "${jail_path}/${SSHD_PID}")
if pkill --parent "${pid}" && kill "${pid}"; then
pkill --parent "${pid}"
if kill "${pid}"; then
notice "${jail_name}: jail has been stopped [${pid}]"
umount --lazy --recursive "${jail_path}/dev"