[gnome-continuous-yocto/gnomeostree-3.28-rocko: 6208/8267] tcf-agent: Fix daemon termination
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-continuous-yocto/gnomeostree-3.28-rocko: 6208/8267] tcf-agent: Fix daemon termination
- Date: Sun, 17 Dec 2017 04:31:20 +0000 (UTC)
commit b467a22729bea886d7bde976c9606ac8e4589cde
Author: Jan Kiszka <jan kiszka web de>
Date: Sun Apr 30 17:28:01 2017 +0200
tcf-agent: Fix daemon termination
The upstream init script uses SIGUSR2 to terminate that daemon because
SIGTERM is ignored. As the killproc function does not support specifying
a signal, switch to start-stop-daemon. Drop the retry loop because
SIGUSR2 is lethal for agent.
(From OE-Core rev: 7a47752f8223f3c0ed4354d5e39f1319071acf41)
Signed-off-by: Jan Kiszka <jan kiszka siemens com>
Signed-off-by: Ross Burton <ross burton intel com>
Signed-off-by: Richard Purdie <richard purdie linuxfoundation org>
.../tcf-agent/tcf-agent/tcf-agent.init | 12 +-----------
1 files changed, 1 insertions(+), 11 deletions(-)
---
diff --git a/meta/recipes-devtools/tcf-agent/tcf-agent/tcf-agent.init
b/meta/recipes-devtools/tcf-agent/tcf-agent/tcf-agent.init
index 6303280..f902085 100755
--- a/meta/recipes-devtools/tcf-agent/tcf-agent/tcf-agent.init
+++ b/meta/recipes-devtools/tcf-agent/tcf-agent/tcf-agent.init
@@ -33,16 +33,7 @@ case "$1" in
stop)
echo -n "Stopping $DAEMON_NAME: "
- count=0
- while [ -n "`/bin/pidof $DAEMON_PATH`" -a $count -lt 10 ] ; do
- killproc $DAEMON_PATH >& /dev/null
- sleep 1
- RETVAL=$?
- if [ $RETVAL != 0 -o -n "`/bin/pidof $DAEMON_PATH`" ] ; then
- sleep 3
- fi
- count=`expr $count + 1`
- done
+ start-stop-daemon -K -q -x $DAEMON_PATH -s USR2
rm -f /var/lock/subsys/$DAEMON_NAME
if [ -n "`/bin/pidof $DAEMON_PATH`" ] ; then
echo "FAIL"
@@ -72,4 +63,3 @@ case "$1" in
esac
exit $RETVAL
-
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]