Mercurial > hg > xemacs-beta
diff src/objects-x.c @ 3169:5bfedec8927e
[xemacs-hg @ 2005-12-24 17:33:31 by aidan]
Move the XListFonts maxnames param to INT_MAX from 5000
author | aidan |
---|---|
date | Sat, 24 Dec 2005 17:33:34 +0000 |
parents | 8f3f6e3dfad9 |
children | 588878f5a654 |
line wrap: on
line diff
--- a/src/objects-x.c Fri Dec 23 22:51:11 2005 +0000 +++ b/src/objects-x.c Sat Dec 24 17:33:34 2005 +0000 @@ -693,8 +693,9 @@ return result; } -/* Unbounded, for sufficiently small values of infinity... */ -#define MAX_FONT_COUNT 5000 +/* XListFonts doesn't allocate memory unconditionally based on this. (For + XFree86 in 2005, at least. */ +#define MAX_FONT_COUNT INT_MAX static Extbyte * truename_via_XListFonts (Display *dpy, Extbyte *font_name) @@ -807,8 +808,7 @@ FcChar8 *res = FcNameUnparse (FONT_INSTANCE_X_XFTFONT (f)->pattern); if (res) { - FONT_INSTANCE_TRUENAME (f) = - build_ext_string (res, Qxft_font_name_encoding); + FONT_INSTANCE_TRUENAME (f) = make_string (res, strlen (res)); free (res); return FONT_INSTANCE_TRUENAME (f); } @@ -1176,7 +1176,7 @@ Extbyte **names; int count = 0; const Extbyte *patternext; - Lisp_Object result = Qnil; + Lisp_Object result = Qunbound; int i; /* #### with Xft need to handle second stage here -- sjt @@ -1442,7 +1442,7 @@ if (x_font_spec_matches_charset (XDEVICE (device), charset, intname, Qnil, 0, -1, 0)) { - result = build_ext_string (intname, Qx_font_name_encoding); + result = make_string (intname, intlen); break; } }