From 86bb55b4c6d25b2b3d21d1404d142d5f66ece3dd Mon Sep 17 00:00:00 2001 From: Chris Lawrence Date: Mon, 18 Aug 2008 16:34:24 -0500 Subject: [PATCH] lsb 3.2-20 Debian release. --- debian/changelog | 9 +++++++++ init-functions | 7 ++++++- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index 90e9409..799b29f 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,12 @@ +lsb (3.2-20) unstable; urgency=low + + * Revert change in 3.2-16 that broke killproc due to my misunderstanding + of the spec. (Closes: #495587) + * pidofproc now also checks for /var/run/$base.pid if -p is not specified, + fixing conformance with the spec. + + -- Chris Lawrence Mon, 18 Aug 2008 16:34:24 -0500 + lsb (3.2-19) unstable; urgency=low * Return 0 in log_failure_msg too. diff --git a/init-functions b/init-functions index 3d6847c..4d99df0 100644 --- a/init-functions +++ b/init-functions @@ -71,6 +71,11 @@ pidofproc () { done shift $(($OPTIND - 1)) + base=${1##*/} + if [ ! "$specified" ]; then + pidfile="/var/run/$base.pid" + fi + if [ -n "${pidfile:-}" -a -e "$pidfile" ]; then read pid < "$pidfile" if [ -n "${pid:-}" ]; then @@ -113,7 +118,7 @@ killproc () { base=${1##*/} if [ ! $pidfile ]; then - name_param="--name $base" + name_param="--name $base --pidfile /var/run/$base.pid" else name_param="--pidfile $pidfile" fi -- 2.30.2