Mercurial > pidgin.yaz
diff pidgin/gtkutils.c @ 20805:e0ce7124d2d4
Fix CID 353
author | Sadrul Habib Chowdhury <imadil@gmail.com> |
---|---|
date | Wed, 10 Oct 2007 01:01:21 +0000 |
parents | a058621fcab1 |
children | f7b799e77c43 7821fa7b22db fc80a99f6f40 |
line wrap: on
line diff
--- a/pidgin/gtkutils.c Wed Oct 10 00:47:28 2007 +0000 +++ b/pidgin/gtkutils.c Wed Oct 10 01:01:21 2007 +0000 @@ -111,19 +111,20 @@ desc = pango_font_description_from_string(font); } else if (purple_running_gnome()) { /* Use the GNOME "document" font, if applicable */ - char *path, *font; + char *path; if ((path = g_find_program_in_path("gconftool-2"))) { + char *font = NULL; g_free(path); - if (!g_spawn_command_line_sync( + if (g_spawn_command_line_sync( "gconftool-2 -g /desktop/gnome/interface/document_font_name", - &font, NULL, NULL, NULL)) - return; + &font, NULL, NULL, NULL)) { + desc = pango_font_description_from_string(font); + } + g_free(font); } - desc = pango_font_description_from_string(font); - g_free(font); } - + if (desc) { gtk_widget_modify_font(imhtml, desc); pango_font_description_free(desc);