Enlightenment CVS committal Author : devilhorns Project : e17 Module : apps/e
Dir : e17/apps/e/src/modules/conf_fonts Modified Files: e_int_config_fonts.c Log Message: If we don't reassign a value to either tc->font or style, then be sure to set them to NULL. This fixes bug #120. =================================================================== RCS file: /cvs/e/e17/apps/e/src/modules/conf_fonts/e_int_config_fonts.c,v retrieving revision 1.1 retrieving revision 1.2 diff -u -3 -r1.1 -r1.2 --- e_int_config_fonts.c 7 Jul 2007 15:44:01 -0000 1.1 +++ e_int_config_fonts.c 20 Jul 2007 08:11:39 -0000 1.2 @@ -205,7 +205,8 @@ E_Font_Properties *efp; efp = e_font_fontconfig_name_parse(efd->font); - tc->font = evas_stringshare_add(efp->name); + if (efp->name) + tc->font = evas_stringshare_add(efp->name); if (efp->styles) tc->style = evas_stringshare_add(efp->styles->data); e_font_properties_free(efp); @@ -226,7 +227,8 @@ E_Font_Properties *efp; efp = e_font_fontconfig_name_parse(efd->font); - tc->font = evas_stringshare_add(efp->name); + if (efp->name) + tc->font = evas_stringshare_add(efp->name); if (efp->styles) tc->style = evas_stringshare_add(efp->styles->data); e_font_properties_free(efp); @@ -399,11 +401,14 @@ if (tc->font) evas_stringshare_del(tc->font); if (cfdata->cur_font) tc->font = evas_stringshare_add(cfdata->cur_font); - + else + tc->font = NULL; + if (tc->style) evas_stringshare_del(tc->style); if (cfdata->cur_style) tc->style = evas_stringshare_add(cfdata->cur_style); - + else + tc->style = NULL; tc->enabled = cfdata->cur_enabled; } @@ -784,9 +789,13 @@ if (tc->font) evas_stringshare_del(tc->font); if (cfdata->cur_font) tc->font = evas_stringshare_add(cfdata->cur_font); + else + tc->font = NULL; if (tc->style) evas_stringshare_del(tc->style); if (cfdata->cur_style) tc->style = evas_stringshare_add(cfdata->cur_style); + else + tc->style = NULL; if (cfdata->gui.style_list) e_widget_ilist_unselect(cfdata->gui.style_list); if (cfdata->gui.size_list) @@ -1120,6 +1129,8 @@ if (tc->style) evas_stringshare_del(tc->style); if (cfdata->cur_style) tc->style = evas_stringshare_add(cfdata->cur_style); + else + tc->style = NULL; } _font_preview_update(cfdata); ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ enlightenment-cvs mailing list enlightenment-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs