Ian Campbell writes ("[PATCH OSSTEST v2 14/18] libvirt: Implement initscript 
restart which has some hope of working."):
...
>    restart)
> -     stop
> -     start
> +     [ "$VERBOSE" != no ] && log_daemon_msg "Restarting $DESC" "$DAEMON"
> +     start-stop-daemon --oknodo --stop --pidfile $PIDFILE --exec $DAEMON
> +     start-stop-daemon --start --pidfile $PIDFILE --exec $DAEMON -- -d 
> $libvirtd_opts
> +     [ "$VERBOSE" != no ] && log_end_msg $?

Well, the old code is pretty bad because the functions start() and
stop() don't exist.  But wouldn't it be better to move the code into
functions, rather than duplicating it ?

(AFAICT the stop code in restart differs in that it uses --oknodo but
you could pass that to your `stop' function.)

Ian.

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

Reply via email to