From: Jason Rumney Date: Sat, 1 Mar 2008 20:21:03 +0000 (+0000) Subject: (font_unparse_fcname): Increase len when style is a symbol. X-Git-Tag: emacs-pretest-23.0.90~7533 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=f3b9e4791f7da7911bd8838c4247b668356c4312;p=emacs.git (font_unparse_fcname): Increase len when style is a symbol. --- diff --git a/src/ChangeLog b/src/ChangeLog index 5bc47181e4e..5d059247940 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2008-03-01 Jason Rumney + + * font.c (font_unparse_fcname): Increase len when style is a symbol. + 2008-03-01 Jan Dj$(Q)Z(Brv * xterm.c (handle_one_xevent): For Gtk+ and ConfigureNotify, call diff --git a/src/font.c b/src/font.c index ce040fe7fd7..9856c935ef6 100644 --- a/src/font.c +++ b/src/font.c @@ -1462,9 +1462,10 @@ font_unparse_fcname (font, pixel_size, name, nbytes) if (INTEGERP (val)) { val = prop_numeric_to_name (i, XINT (val)); - len += (strlen (style_names[i - FONT_WEIGHT_INDEX]) - + 2 + SBYTES (SYMBOL_NAME (val))); /* :xxx=NAME */ } + if (SYMBOLP (val) && ! NILP (val)) + len += (strlen (style_names[i - FONT_WEIGHT_INDEX]) + + 2 + SBYTES (SYMBOL_NAME (val))); /* :xxx=NAME */ styles[i - FONT_WEIGHT_INDEX] = val; }