From: Lennart Poettering Date: Thu, 27 Mar 2008 00:39:09 +0000 (+0000) Subject: Make init scripts fail faster; patch from scop X-Git-Url: https://git.meshlink.io/?a=commitdiff_plain;h=4079dd94f3425d503b5db5faca6561151a3b209f;p=catta Make init scripts fail faster; patch from scop git-svn-id: file:///home/lennart/svn/public/avahi/trunk@1757 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe --- diff --git a/initscript/fedora/avahi-daemon.in b/initscript/fedora/avahi-daemon.in index 69fac9b..d309866 100644 --- a/initscript/fedora/avahi-daemon.in +++ b/initscript/fedora/avahi-daemon.in @@ -10,12 +10,6 @@ # processname: avahi-daemon # config: -OTHER_AVAHI_OPTS="" - -# Source function library. -. /etc/init.d/functions -. /etc/sysconfig/network - AVAHI_BIN=@sbindir@/avahi-daemon if [ "$1" == 'status' ]; then @@ -24,6 +18,12 @@ else test -x $AVAHI_BIN || exit 5 fi +OTHER_AVAHI_OPTS="" + +# Source function library. +. /etc/init.d/functions +. /etc/sysconfig/network + LOCKFILE=/var/lock/subsys/avahi-daemon base=${0##*/} diff --git a/initscript/fedora/avahi-dnsconfd.in b/initscript/fedora/avahi-dnsconfd.in index a29cf1a..284c10b 100644 --- a/initscript/fedora/avahi-dnsconfd.in +++ b/initscript/fedora/avahi-dnsconfd.in @@ -10,12 +10,6 @@ # processname: avahi-dnsconfd # config: -OTHER_AVAHI_OPTS="" - -# Source function library. -. /etc/init.d/functions -. /etc/sysconfig/network - AVAHI_BIN=@sbindir@/avahi-dnsconfd if [ "$1" == 'status' ]; then @@ -24,6 +18,12 @@ else test -x $AVAHI_BIN || exit 5 fi +OTHER_AVAHI_OPTS="" + +# Source function library. +. /etc/init.d/functions +. /etc/sysconfig/network + LOCKFILE=/var/lock/subsys/avahi-dnsconfd base=${0##*/} diff --git a/initscript/mandriva/avahi-daemon.in b/initscript/mandriva/avahi-daemon.in index 2efbc6e..f285d3b 100644 --- a/initscript/mandriva/avahi-daemon.in +++ b/initscript/mandriva/avahi-daemon.in @@ -8,6 +8,9 @@ # Description: Avahi, a ZeroConf daemon whichs implements an mDNS stack ### END INIT INFO +AVAHI_BIN=@sbindir@/avahi-daemon +test -x $AVAHI_BIN || exit 5 + # Source function library. . /etc/init.d/functions @@ -16,9 +19,6 @@ # Check that networking is configured. [ ${NETWORKING} = "no" ] && exit 0 -AVAHI_BIN=@sbindir@/avahi-daemon -test -x $AVAHI_BIN || exit 5 - start() { echo -n $"Starting Avahi daemon: " $AVAHI_BIN -D diff --git a/initscript/mandriva/avahi-dnsconfd.in b/initscript/mandriva/avahi-dnsconfd.in index 3e8aaaf..a221356 100644 --- a/initscript/mandriva/avahi-dnsconfd.in +++ b/initscript/mandriva/avahi-dnsconfd.in @@ -8,6 +8,9 @@ # Description: A DNS configuration daemon using mDNS in a DHCP-like fashion ### END INIT INFO +AVAHI_BIN=@sbindir@/avahi-dnsconfd +test -x $AVAHI_BIN || exit 5 + # Source function library. . /etc/init.d/functions @@ -16,9 +19,6 @@ # Check that networking is configured. [ ${NETWORKING} = "no" ] && exit 0 -AVAHI_BIN=@sbindir@/avahi-dnsconfd -test -x $AVAHI_BIN || exit 5 - start() { echo -n $"Starting Avahi DNS daemon: " $AVAHI_BIN -D