summary refs log tree commit diff
path: root/xutil.c
diff options
context:
space:
mode:
Diffstat (limited to 'xutil.c')
-rw-r--r--xutil.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/xutil.c b/xutil.c
index 3c4d004..847b148 100644
--- a/xutil.c
+++ b/xutil.c
@@ -291,7 +291,10 @@ xu_ewmh_net_desktop_names(struct screen_ctx *sc, char *data, int n)
 void
 xu_ewmh_net_wm_desktop(struct client_ctx *cc)
 {
-	long	 num = cc->group->num;
+	long	 num = 0xffffffff;
+
+	if (cc->group)
+		num = cc->group->num;
 
 	XChangeProperty(X_Dpy, cc->win, ewmh[_NET_WM_DESKTOP],
 	    XA_CARDINAL, 32, PropModeReplace, (unsigned char *)&num, 1);