From 101305e1c7dc24f5a40e80a900b0777b2634722f Mon Sep 17 00:00:00 2001 From: Milan Crha Date: Tue, 7 Sep 2010 18:39:46 +0200 Subject: Various memory leaks --- shell/e-shell-content.c | 5 +++++ shell/e-shell-searchbar.c | 5 +++++ shell/e-shell.c | 2 +- 3 files changed, 11 insertions(+), 1 deletion(-) (limited to 'shell') diff --git a/shell/e-shell-content.c b/shell/e-shell-content.c index 5173ee8c83..527ef250a6 100644 --- a/shell/e-shell-content.c +++ b/shell/e-shell-content.c @@ -142,6 +142,11 @@ shell_content_dispose (GObject *object) priv->shell_view = NULL; } + if (priv->user_filename) { + g_free (priv->user_filename); + priv->user_filename = NULL; + } + /* Chain up to parent's dispose() method. */ G_OBJECT_CLASS (e_shell_content_parent_class)->dispose (object); } diff --git a/shell/e-shell-searchbar.c b/shell/e-shell-searchbar.c index cb525f8f85..9a7800fdab 100644 --- a/shell/e-shell-searchbar.c +++ b/shell/e-shell-searchbar.c @@ -648,6 +648,11 @@ shell_searchbar_dispose (GObject *object) priv->search_option = NULL; } + if (priv->state_group) { + g_free (priv->state_group); + priv->state_group = NULL; + } + /* Chain up to parent's dispose() method. */ G_OBJECT_CLASS (e_shell_searchbar_parent_class)->dispose (object); } diff --git a/shell/e-shell.c b/shell/e-shell.c index db9efc9331..93832ec7fe 100644 --- a/shell/e-shell.c +++ b/shell/e-shell.c @@ -329,7 +329,7 @@ shell_ready_for_quit (EShell *shell, shell_ready_for_quit, shell); /* Finalize the activity. */ - g_object_ref (activity); + g_object_unref (activity); /* Destroy all watched windows. Note, we iterate over a -copy- * of the watched windows list because the act of destroying a -- cgit v1.2.3