X-Git-Url: http://xvm.mit.edu/gitweb/invirt/packages/invirt-vnc-server.git/blobdiff_plain/115d1b8e6398ba73ce5793074f78d8f0b129c483..74234af2797b0475bf18de16a0bfe3bd6a7218a1:/debian/invirt-vnc-server.init?ds=sidebyside diff --git a/debian/invirt-vnc-server.init b/debian/invirt-vnc-server.init index a096c57..e37e47a 100644 --- a/debian/invirt-vnc-server.init +++ b/debian/invirt-vnc-server.init @@ -18,8 +18,8 @@ PACKAGE=invirt-vnc-server DESC="The Invirt VNC Proxy Server" DAEMON=/usr/sbin/invirt-vnc-server DAEMON_ARGS="" -PIDFILE=/var/run/$NAME.pid -SCRIPTNAME=/etc/init.d/$NAME +PIDFILE=/var/run/$PACKAGE.pid +SCRIPTNAME=/etc/init.d/$PACKAGE # Exit if the package is not installed [ -x "$DAEMON" ] || exit 0 @@ -35,8 +35,8 @@ do_start() # 0 if daemon has been started # 1 if daemon was already running # 2 if daemon could not be started - daemon --running -n $NAME && return 1 - daemon -r -U -O daemon.info -E daemon.err -n $NAME -U $DAEMON $DAEMON_ARGS || return 2 + daemon --running -n $PACKAGE && return 1 + daemon -r -U -O daemon.info -E daemon.err -n $PACKAGE -U $DAEMON $DAEMON_ARGS || return 2 } # @@ -49,7 +49,7 @@ do_stop() # 1 if daemon was already stopped # 2 if daemon could not be stopped # other if a failure occurred - daemon --stop -n $NAME + daemon --stop -n $PACKAGE RETVAL="$?" [ "$RETVAL" = 2 ] && return 2 # Many daemons don't delete their pidfiles when they exit.