From b73d2475a76c6b59dde700416f1fed8d29cab562 Mon Sep 17 00:00:00 2001 From: Tollef Fog Heen Date: Mon, 6 Apr 2015 19:28:03 +0200 Subject: [PATCH] Use start-stop-daemon for stopping/restarting stunnel4 --- modules/stunnel4/files/etc-init.d-stunnel4 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/stunnel4/files/etc-init.d-stunnel4 b/modules/stunnel4/files/etc-init.d-stunnel4 index 6456bfb7d..7bc871ac6 100755 --- a/modules/stunnel4/files/etc-init.d-stunnel4 +++ b/modules/stunnel4/files/etc-init.d-stunnel4 @@ -76,9 +76,9 @@ killdaemons() { for file in $FILES; do PROCLIST=`get_pids $file` - if [ "$PROCLIST" ] && kill -0 $PROCLIST 2>/dev/null; then - kill $PROCLIST - echo -n "[stopped: $file] " + for p in $PROCLIST; do + start-stop-daemon --stop --retry 30 --pid "$p" + echo -n "[stopped: $file] " fi done } -- 2.20.1