Subject: small bugfix in twm
To: None <>
From: Aymeric Vincent <>
List: tech-x11
Date: 07/23/2001 12:37:15

here's a small patch to prevent twm from dumping core when a window
title is empty.

As I don't know how to coordinate this with the XFree86 team, I
thought it could be as well made part of bigger changes by someone

So here it is; I don't intend to commit this myself as it would
unnecessarily desynchronize us from XF86.

thanks to anyone who will take this,

PS: note that this applies to the XF4 part of our tree; the same patch
    should be applied to the 3.3.6 branch.

Index: add_window.c
RCS file: /cvsroot/xsrc/xfree/xc/programs/twm/add_window.c,v
retrieving revision
diff -u -r1.1.1.3 add_window.c
--- add_window.c	2001/06/09 15:10:59
+++ add_window.c	2001/07/23 10:32:41
@@ -198,7 +198,8 @@
     XGetWindowAttributes(dpy, tmp_win->w, &tmp_win->attr);
-    I18N_FetchName(dpy, tmp_win->w, &name);
+    if (!I18N_FetchName(dpy, tmp_win->w, &name))
+	name = NULL;
     tmp_win->class = NoClass;
     XGetClassHint(dpy, tmp_win->w, &tmp_win->class);
     FetchWmProtocols (tmp_win);