--- a/jdk/src/java.desktop/unix/native/common/awt/fontpath.c Thu Aug 13 16:26:17 2015 +0300
+++ b/jdk/src/java.desktop/unix/native/common/awt/fontpath.c Thu Aug 13 12:12:10 2015 -0700
@@ -1219,10 +1219,11 @@
minGlyphs = val;
}
}
+ FcCharSet *unionCharset = NULL;
for (j=0; j<nfonts; j++) {
FcPattern *fontPattern = fontset->fonts[j];
FcChar8 *fontformat;
- FcCharSet *unionCharset = NULL, *charset;
+ FcCharSet *charset = NULL;
fontformat = NULL;
(*FcPatternGetString)(fontPattern, FC_FONTFORMAT, 0, &fontformat);
@@ -1280,6 +1281,9 @@
if (!includeFallbacks) {
break;
}
+ if (fontCount == 254) {
+ break; // CompositeFont will only use up to 254 slots from here.
+ }
}
/* Once we get here 'fontCount' is the number of returned fonts