aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--shell/ChangeLog7
-rw-r--r--shell/e-shell-folder-title-bar.c7
2 files changed, 12 insertions, 2 deletions
diff --git a/shell/ChangeLog b/shell/ChangeLog
index df80470579..c8685b82c0 100644
--- a/shell/ChangeLog
+++ b/shell/ChangeLog
@@ -1,3 +1,10 @@
+2001-08-21 Ettore Perazzoli <ettore@ximian.com>
+
+ * e-shell-folder-title-bar.c (label_realize_callback): Fix a leak:
+ unref the EFont after we have used it. Also, don't crash if
+ `e_font_to_gdk_font()' returns NULL. [This should fix #7666,
+ Folder View crashes Evo.]
+
2001-08-21 Iain Holmes <iain@ximian.com>
* e-shell-importer.c (start_import): Don't print a NULL.
diff --git a/shell/e-shell-folder-title-bar.c b/shell/e-shell-folder-title-bar.c
index 836da098cb..1ed1dcca6e 100644
--- a/shell/e-shell-folder-title-bar.c
+++ b/shell/e-shell-folder-title-bar.c
@@ -147,9 +147,12 @@ label_realize_callback (GtkWidget *widget,
e_font = e_font_from_gdk_font (style->font);
bolded_font = e_font_to_gdk_font (e_font, E_FONT_BOLD);
+ e_font_unref (e_font);
- gdk_font_unref (style->font);
- style->font = bolded_font;
+ if (bolded_font != NULL) {
+ gdk_font_unref (style->font);
+ style->font = bolded_font;
+ }
gtk_style_attach (style, widget->window);