Use xfree, not free, to avoid crash with --enable-checking=xmallocoverrun.
[bpt/emacs.git] / lwlib / lwlib-Xaw.c
index 9c9a007..0eea0ab 100644 (file)
@@ -136,7 +136,7 @@ openFont (Widget widget, char *name)
     }
 
   fn = XftFontOpenName (XtDisplay (widget), screen, fname);
-  if (fname != name) free (fname);
+  if (fname != name) xfree (fname);
 
   return fn;
 }
@@ -384,7 +384,7 @@ xaw_destroy_instance (widget_instance *instance)
       if (instance->xft_data[0].xft_font)
         XftFontClose (XtDisplay (instance->widget),
                       instance->xft_data[0].xft_font);
-      free (instance->xft_data);
+      xfree (instance->xft_data);
     }
 #endif
   if (XtIsSubclass (instance->widget, dialogWidgetClass))