tags 494974 + patch thanks Hi Timo!
On Wed, 13 Aug 2008 16:27:28 +0200, Timo Juhani Lindfors wrote:
> ginger:~# /etc/init.d/zhone-session restart
> /usr/bin/xinit already running.
This is mostly annoying when you upgrade zhone-session, since the
upgrade exits with an error. The following patch is a possible
solution, for sure not the best, but anyway Joachim is improving the
general situation (and I don't like non-fixed bugs).
--8<---------------cut here---------------start------------->8---
--- /etc/init.d/zhone-session.ORG 2008-09-04 21:57:57.000000000 +0200
+++ /etc/init.d/zhone-session 2008-09-04 22:04:32.000000000 +0200
@@ -35,8 +35,12 @@
case "$1" in
start)
[ "$VERBOSE" != no ] && log_daemon_msg "Starting $DESC" "$NAME"
- start-stop-daemon --start --pidfile ${PIDFILE} --make-pidfile
--background --exec ${PROG_XINIT} -- ${PROG_XSESSION} ${PROG_FSO} -- $X_OPTIONS
- [ "$VERBOSE" != no ] && log_end_msg $?
+ if pidof /usr/bin/xinit >/dev/null; then
+ echo "W: zhone-session is already running, not starting."
+ else
+ start-stop-daemon --start --pidfile ${PIDFILE} --make-pidfile
--background --exec ${PROG_XINIT} -- ${PROG_XSESSION} ${PROG_FSO} -- $X_OPTIONS
+ [ "$VERBOSE" != no ] && log_end_msg $?
+ fi
;;
stop)
[ "$VERBOSE" != no ] && log_daemon_msg "Stopping $DESC" "$NAME"
--8<---------------cut here---------------end--------------->8---
Comments?
Thx, bye,
Gismo / Luca
pgp0JKeb0zgmm.pgp
Description: PGP signature

