summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <zecke@selfish.org>2013-06-20 11:15:45 +0200
committerHolger Hans Peter Freyther <zecke@selfish.org>2013-06-20 11:17:53 +0200
commit0db898e4b8870ecc8e703ca3b6cafb6281077188 (patch)
tree02b97669b3e385c73a50ef058a1d1f3a9b420cb4
parentf07a52709feca7a7f75a3d637a6f1ad5df6e3fa4 (diff)
downloadgpsdate-0db898e4b8870ecc8e703ca3b6cafb6281077188.tar.gz
gpsdate-0db898e4b8870ecc8e703ca3b6cafb6281077188.tar.bz2
gpsdate-0db898e4b8870ecc8e703ca3b6cafb6281077188.tar.xz
gpsdate-0db898e4b8870ecc8e703ca3b6cafb6281077188.zip
gpsdate.init: Make the killing of gpsdate work on the target
When the initscript is called gpsdate it might kill itself before it has a way to start the new gpsdate process. Use pidof with the full path to the gpsdate binary to avoid this.
-rwxr-xr-xgpsdate.init2
1 files changed, 1 insertions, 1 deletions
diff --git a/gpsdate.init b/gpsdate.init
index 7810af6..bfd40f4 100755
--- a/gpsdate.init
+++ b/gpsdate.init
@@ -52,7 +52,7 @@ case "$1" in
stop)
# This should use start-stop-daemon and create a pid file
echo "Stopping gpsdate in a brutal way"
- killall -9 gpsdate
+ kill -9 `pidof $DAEMON`
;;
restart)