Re: [dwm] input status text bug?

From: Anselm R. Garbe <arg_AT_suckless.org>
Date: Sat, 3 Nov 2007 20:49:38 +0100

On Fri, Nov 02, 2007 at 10:49:18PM +0100, Sander van Dijk wrote:
> On Nov 2, 2007 10:02 PM, Anselm R. Garbe <arg_AT_suckless.org> wrote:
> > Hmm, if that's the reason I tend to write a read()-based getline
> > function which does not block ;)
>
> Try doing this:
>
> for i in `seq 1 10`
> do
> echo -n bla
> if test "$i" = 5
> then
> echo
> fi
> sleep 3
> done | dwm
>
> Than dwm will be unresponsive for a while, after some time it'll
> update the statustext as "blablablablabla" and continue to be
> unresponsive.

Well I extended the old low-level approach with an offset
handling, and your example and all others work really quite well
now (recheck hg tip).

One thing which behaves differently now is, that dwm will drop
subsequent multiline data except the first line during a single
read(). This approach makes the algorithm more readable and
elegant, and usually nobody writes more than a single line to
dwm per status update.

Regards,

-- 
 Anselm R. Garbe >< http://www.suckless.org/ >< GPG key: 0D73F361
Received on Sat Nov 03 2007 - 20:49:38 UTC

This archive was generated by hypermail 2.2.0 : Sun Jul 13 2008 - 15:04:32 UTC