If FcFontList returns an empty FcFontSet synfig will crash because fs->fonts is a NULL pointer. Avoid that crash by checking the number of returned fonts.
Signed-off-by: Olaf Hering <o...@aepfle.de> --- src/modules/lyr_freetype/lyr_freetype.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Index: synfig-1.0/src/modules/lyr_freetype/lyr_freetype.cpp =================================================================== --- synfig-1.0.orig/src/modules/lyr_freetype/lyr_freetype.cpp +++ synfig-1.0/src/modules/lyr_freetype/lyr_freetype.cpp @@ -408,7 +408,7 @@ Layer_Freetype::new_face(const String &n FcFontSetAdd(fs, match); if (pat) FcPatternDestroy(pat); - if(fs){ + if(fs && fs->nfont){ FcChar8* file; if( FcPatternGetString (fs->fonts[0], FC_FILE, 0, &file) == FcResultMatch ) error=FT_New_Face(ft_library,(const char*)file,face_index,&face); ------------------------------------------------------------------------------ Monitor 25 network devices or servers for free with OpManager! OpManager is web-based network management software that monitors network devices and physical & virtual servers, alerts via email & sms for fault. Monitor 25 devices for free with no restriction. Download now http://ad.doubleclick.net/ddm/clk/292181274;119417398;o _______________________________________________ Synfig-devl mailing list Synfig-devl@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/synfig-devl