Re: [dwm] dwm exits with segm fault after last compile

From: Anselm R. Garbe <arg_AT_suckless.org>
Date: Sat, 21 Jun 2008 17:22:18 +0200

On Sat, Jun 21, 2008 at 06:45:22AM -0700, Leandro Chescotta wrote:
> I followed this steps, first i was using dmenu 3.4 in extra, then i
> see that dwm doesn't launch dmenu with ALT+p, then i asked and get as
> answer to install dmenu 3.7, compile dmenu 3.7 and perfectly works,
> all works perfectly as a rock, ALT+p to launch apps with dmenu, and
> ALT+enter to launch terminals, all perfect... then i decided to change
> the colors a little and add a few programs to the floating layer
> (experimenting to get mplayer in the front instead that in the
> background) and compile again dwm, but this time, everytime i launch
> urxvt via ALT+enter the bar dissapear and after a second X exits and i
> can see a segmentation fault, same if i press ALT+p to get dmenu and
> launch something sad sad that this actually happend before sleep when
> i just configure and understand dwm for the first time tongue (i'm
> back in wmii now) but i wanna change to dwm because i feel it more
> that i want sad

Your session segfaults, because your Rules-config is wrong:

> static Rule rules[] = {
> /* class instance title tags mask isfloating */
> { "Gimp", NULL, True },
> { "pidgin", NULL, NULL, 0, True },
> { "mplayer", NULL, NULL, 0, True },
> { "vlc", NULL, NULL, 0, True },
> { "xine", NULL, NULL, 0, True },
> { "xmms", NULL, NULL, 0, True },
> { "gkrellm", NULL, NULL, 0, True },
> };

In your first rule title is set to True, which means it will
point to 0x1, so this is used in a strcmp and will crash because
you access memory which isn't allowed to be (SEGFAULT).

Restoring the first rule to the original one should fix your
problem:

        { "Gimp", NULL, NULL, 0, True },

> 1) get mplayer working right in dwm, i get a tiled mplayer window when
> i understand that it must be in the floating layer, and if i press f
> for fullscreen i get it fullscreen but below the other apps not in top
> off all

Well as long as above rules aren't working, mplayer won't be
considered as floating app.

> 2) when havin two terminals in the same tag, have one below the other
> and not side-by-side? in wmii all apps open one below the other by
> default and i like it that way, and i can press ALT+SHIFT+l and get
> the apps side-by-si

That's not possible without implementing your own layout. See
tile() or in hg tip (upcoming 5.1) for monocle() to get an idea
how you can easily achieve this layout you like.

Just implement the layout function in config.h or include the
layout function from some file in config.h.

Kind regards,

-- 
 Anselm R. Garbe >< http://www.suckless.org/ >< GPG key: 0D73F361
Received on Sat Jun 21 2008 - 17:22:18 UTC

This archive was generated by hypermail 2.2.0 : Sun Jul 13 2008 - 15:50:42 UTC