# HG changeset patch # User stephent # Date 1135339245 0 # Node ID c9423e7289d28995d1974ef4bc767c3cd5af99a0 # Parent 04a435415e1d8bb815a3f4e7237fc0ea367f10f5 [xemacs-hg @ 2005-12-23 12:00:44 by stephent] Fix crash getting truename of Xft fonts. <878xuc2fdo.fsf@tleepslib.sk.tsukuba.ac.jp> diff -r 04a435415e1d -r c9423e7289d2 src/ChangeLog --- a/src/ChangeLog Fri Dec 23 11:42:35 2005 +0000 +++ b/src/ChangeLog Fri Dec 23 12:00:45 2005 +0000 @@ -1,3 +1,8 @@ +2005-12-23 Stephen J. Turnbull + + * objects-x.c (x_font_instance_truename): Mule-ize handling of + font name (Xft names are UTF-8). Fixes crash. + 2005-12-20 Aidan Kehoe * objects-x.c (x_find_charset_font): diff -r 04a435415e1d -r c9423e7289d2 src/objects-x.c --- a/src/objects-x.c Fri Dec 23 11:42:35 2005 +0000 +++ b/src/objects-x.c Fri Dec 23 12:00:45 2005 +0000 @@ -807,7 +807,8 @@ FcChar8 *res = FcNameUnparse (FONT_INSTANCE_X_XFTFONT (f)->pattern); if (res) { - FONT_INSTANCE_TRUENAME (f) = make_string (res, strlen (res)); + FONT_INSTANCE_TRUENAME (f) = + build_ext_string (res, Qxft_font_name_encoding); free (res); return FONT_INSTANCE_TRUENAME (f); }