applied XGetWMNormalHints fix
authorAnselm R Garbe <garbeam@gmail.com>
Sun, 07 Sep 2008 09:53:59 +0100
changeset 1357 33591b7c6bf7
parent 1356 d2658eac8ff9
child 1358 e4bcaca8e6ef
applied XGetWMNormalHints fix
dwm.c
--- a/dwm.c	Sat Sep 06 09:34:49 2008 +0100
+++ b/dwm.c	Sun Sep 07 09:53:59 2008 +0100
@@ -1590,7 +1590,9 @@
 	long msize;
 	XSizeHints size;
 
-	XGetWMNormalHints(dpy, c->win, &size, &msize);
+	if(!XGetWMNormalHints(dpy, c->win, &size, &msize))
+		/* size is uninitialized, ensure that size.flags aren't used */
+		size.flags = PSize; 
 	if(size.flags & PBaseSize) {
 		c->basew = size.base_width;
 		c->baseh = size.base_height;