Re: [dwm] dwm-5.3

From: Jeremy Jay <dinkumator_AT_gmail.com>
Date: Fri, 5 Dec 2008 10:14:44 -0500

I have the same problem, although my status feed setup is nearly identical
to the one Neale shows. I use 'tail -f $XSTATUS | dwm' instead of 'dwm <
$XSTATUS' because for some reason dwm always showed EOF the other way.

Anyways, my .xinitrc is simply 'exec dwm-launch' and dwm-launch does the
fifo mess, starts the status script in bg, and starts up stalonetray and
nm-applet also in the background. No pid tracking or 'kill' commands.

When I quit with nothing but these running, X closes fine. but when I
quit with an xterm running, X blocks until I close the xterm. So, I
don't think this is the problem.

Jeremy

On Fri 05 Dec 2008 - 08:33AM, Anselm R Garbe wrote:
> 2008/12/5 Neale Pickett <neale_AT_woozle.org>:
> > Neale Pickett <neale_AT_woozle.org> writes:
> >
> >> Would you mind sharing how you launch dwm?
> >
> > It might also be helpful to share your status script. If you launch
> > your status script like this:
> >
> > status | dwm
> >
> > and status forks, the parent may not be exiting.
> >
> > If the status program never exits, X won't terminate when you kill dwm.
> > To test if yours operates this way, try the following experiment:
> >
> > xterm1$ status | cat
> > xterm2$ kill (pid of cat)
> >
> > My status program at least keeps on running even though it can no longer
> > write to stdout. I think it's because the parent shell, the one outside
> > the loop, never gets the SIGPIPE and keeps on running. I'll play with
> > it and report back.
> >
> > This problem isn't related to the recent fork patch, tough; you can
> > reproduce this behavior without ever calling spawn.
> >
> > The reason this doesn't stop X is because your .xsession (or .xinitrc)
> > is waiting for all subprocesses to exit. As long as status keeps
> > running, .xsession won't exit, and the X server startup script won't
> > kill the X server.
> >
> > Here's something you can put in .xsession to run status as a background
> > process and cause your .xsession to exit when dwm exits:
> >
> > XSTATUS=$HOME/.status.$(hostname).$DISPLAY
> > mkfifo -m 600 $XSTATUS
> > status > $XSTATUS &
> > STATUS_PID=$!
> > dwm < $XSTATUS
> > kill $STATUS_PID
> > rm $XSTATUS
>
> I also think this is rather related to the status feed.
>
> Kind regards,
> --Anselm
>
Received on Fri Dec 05 2008 - 15:14:44 UTC

This archive was generated by hypermail 2.2.0 : Fri Dec 05 2008 - 15:24:04 UTC