changeset 3286:b3ab8c197518

[xemacs-hg @ 2006-03-17 14:30:43 by stephent] eliminate bogus pointer to nowhere in x_font_instance_truename <874q1xgn5d.fsf@tleepslib.sk.tsukuba.ac.jp>
author stephent
date Fri, 17 Mar 2006 14:30:45 +0000
parents aac38be9d24e
children 681d0fbb904e
files src/ChangeLog src/objects-x.c
diffstat 2 files changed, 6 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/src/ChangeLog	Thu Mar 16 22:51:09 2006 +0000
+++ b/src/ChangeLog	Fri Mar 17 14:30:45 2006 +0000
@@ -1,3 +1,8 @@
+2006-03-17  Stephen J. Turnbull  <stephen@xemacs.org>
+
+	* objects-x.c (x_font_instance_truename):
+	Eliminate bogus pointer to nowhere.
+
 2006-03-09  Jerry James  <james@xemacs.org>
 
 	* profile.h (RETURN_UNGCPRO_EXIT_PROFILING): Add missing do.
--- a/src/objects-x.c	Thu Mar 16 22:51:09 2006 +0000
+++ b/src/objects-x.c	Fri Mar 17 14:30:45 2006 +0000
@@ -794,7 +794,6 @@
   struct device *d = XDEVICE (f->device);
   Display *dpy = DEVICE_X_DISPLAY (d);
   Extbyte *nameext;
-  char* xlfd;
 
   /* #### restructure this so that we return a valid truename at the end,
      and otherwise only return when we return something desperate that
@@ -827,9 +826,7 @@
   if (NILP (FONT_INSTANCE_TRUENAME (f))
       && FONT_INSTANCE_X_FONT (f))
     {
-      nameext = &xlfd[0];
-      LISP_STRING_TO_EXTERNAL (f->name, nameext, Qx_font_name_encoding);
-
+      nameext = NEW_LISP_STRING_TO_EXTERNAL (f->name, Qx_font_name_encoding);
       FONT_INSTANCE_TRUENAME (f) =
 	x_font_truename (dpy, nameext, FONT_INSTANCE_X_FONT (f));
     }