diff src/font-mgr.h @ 4757:a23ac8f90a49

Improve warning and error messages from Xft. Default debug-level messages off. Cast away Xft warnings from C compiler.
author Stephen J. Turnbull <stephen@xemacs.org>
date Wed, 18 Nov 2009 15:25:00 +0900
parents dfd878799ef0
children 75975fd0b7fc
line wrap: on
line diff
--- a/src/font-mgr.h	Wed Nov 18 11:28:58 2009 +0900
+++ b/src/font-mgr.h	Wed Nov 18 15:25:00 2009 +0900
@@ -146,9 +146,11 @@
 #define PRINT_XFT_PATTERN(level,format,pattern)			\
   do {								\
     DECLARE_EISTRING (eistrpxft_name);				\
-    FcChar8 *name = FcNameUnparse (pattern);			\
+    Extbyte *name = (Extbyte *) FcNameUnparse (pattern);	\
 								\
-    eicpy_ext(eistrpxft_name, name, Qfc_font_name_encoding);	\
+    eicpy_ext(eistrpxft_name,					\
+              name ? name : "FONT WITH NULL NAME",		\
+              Qfc_font_name_encoding);				\
     DEBUG_XFT1 (level, format, eidata(eistrpxft_name));		\
     free (name);						\
   } while (0)