From: Julien Cristau Date: Fri, 4 May 2018 15:05:14 +0000 (+0200) Subject: Fix acquire-reboot-lock molly-guard hook to actually keep the lock until shutdown X-Git-Url: https://git.adam-barratt.org.uk/?a=commitdiff_plain;h=ea0bd030bcd9328567e5558151c0e200581c51c9;p=mirror%2Fdsa-puppet.git Fix acquire-reboot-lock molly-guard hook to actually keep the lock until shutdown RT#6893 --- diff --git a/modules/debian_org/files/molly-guard/15-acquire-reboot-lock b/modules/debian_org/files/molly-guard/15-acquire-reboot-lock index ebbac937b..c97861bfa 100644 --- a/modules/debian_org/files/molly-guard/15-acquire-reboot-lock +++ b/modules/debian_org/files/molly-guard/15-acquire-reboot-lock @@ -11,9 +11,8 @@ if ! flock --exclusive -w 0 3; then fi echo "Reboot lock acquired." -ppid="$PPID" ( - while kill -0 "$ppid" 2>/dev/null; do + while dsa-is-shutdown-scheduled; do sleep 1 done ) &