On Thu, 18 May 2006, Matthias Clasen wrote: > On Wed, 2006-05-17 at 19:40 -0400, James Cloos wrote: > > Changing line 194 of your patch from: > > > > if ( strike_index != 0xFFFFU ) > > > > to > > > > if ( strike_index != 0xFFFFU && ft_face->available_sizes != NULL) > > > > avoids a NULL dereference in FT_Do_SBit_Metrics() in ftfuncs.c. > > > > After that change I can't crash xfs, but any ttf font (sfnt/glyf font) > > showns only odd glyphs in a 16bit encoding such as iso10646-1. 8bit > > encodings work fine, as do type1 fonts.
Testing the patch, I'm getting another crash for a Type1 font: #0 0x003ea427 in FT_Do_SBit_Metrics (ft_face=0x8a394c8, ft_size=0x8a21328, strike_index=0, glyph_index=0, metrics_return=0xbff4d58c, sbitchk_incomplete_but_exist=0xbff4d588) at ftfuncs.c:989 #1 0x003ea60a in FreeTypeRasteriseGlyph (idx=0, flags=1, tgp=0x8a3fa00, instance=0x8a21210, hasMetrics=0) at ftfuncs.c:1128 #2 0x003e9834 in FreeTypeInstanceGetGlyph (idx=0, flags=1, g=0xbff4d768, instance=0x8a21210) at ftfuncs.c:711 #3 0x003f1143 in FreeTypeLoadXFont (fileName=0xbff4de43 "/usr/share/X11/fonts/Type1/UTBI____.pfa", vals=0xbff4ddd4, xf=0x0, info=0xbff4eaec, bmfmt=0xbff4d974, entry=0x89680c0) at ftfuncs.c:3458 #4 0x003f1dcd in FreeTypeGetInfoScalable (fpe=0x8929a08, info=0xbff4eaec, entry=0x89680c0, fontName=0xbff4de38, fileName=0xbff4de43 "/usr/share/X11/fonts/Type1/UTBI____.pfa", vals=0xbff4ddd4) at ftfuncs.c:3874 #5 0x003e569a in FontFileListOneFontWithInfo (client=0x8a03900, fpe=0x8929a08, namep=0xbff4eaa8, namelenp=0xbff4eaa4, pFontInfo=0xbff4eb4c) at fontfile.c:1010 #6 0x003e57bf in FontFileListNextFontWithInfo (client=0x8a03900, fpe=0x8929a08, namep=0xbff4eb58, namelenp=0xbff4eb54, pFontInfo=0xbff4eb4c, numFonts=0xbff4eb50, private=0x8a26070) at fontfile.c:1048 #7 0x0805057b in init_fs_handlers () #8 0x08050d1f in init_fs_handlers () #9 0x0804d640 in set_font_authorizations () #10 0x0804dddf in set_font_authorizations () #11 0x080525f6 in init_fs_handlers () #12 0x00126724 in __libc_start_main () from /lib/libc.so.6 #13 0x0804a451 in ?? () Seems like ft_face->available_sizes is NULL. --behdad http://behdad.org/ "Commandment Three says Do Not Kill, Amendment Two says Blood Will Spill" -- Dan Bern, "New American Language" _______________________________________________ Freetype-devel mailing list Freetype-devel@nongnu.org http://lists.nongnu.org/mailman/listinfo/freetype-devel