[goffice] GogTheme: plug leak.
- From: Morten Welinder <mortenw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [goffice] GogTheme: plug leak.
- Date: Sun, 28 Oct 2012 20:39:41 +0000 (UTC)
commit baa5f6b4ff9196b6ab5e16453515ef543c32641f
Author: Morten Welinder <terra gnome org>
Date: Sun Oct 28 16:39:26 2012 -0400
GogTheme: plug leak.
ChangeLog | 5 +++++
NEWS | 1 +
goffice/graph/gog-theme.c | 11 +++++++----
3 files changed, 13 insertions(+), 4 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 867fcef..07f45c0 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2012-10-28 Morten Welinder <terra gnome org>
+
+ * goffice/graph/gog-theme.c (gog_theme_finalize): Get rid of ->dcm
+ too.
+
2012-10-28 Jean Brefort <jean brefort normalesup org>
* goffice/Makefile.am: new objects.
diff --git a/NEWS b/NEWS
index 817f564..0d258b4 100644
--- a/NEWS
+++ b/NEWS
@@ -23,6 +23,7 @@ Jean:
Morten:
* Namespace cleanup. [#686501]
* Fix EE-format compilation. [#686480]
+ * Plug leak.
--------------------------------------------------------------------------
goffice 0.9.6:
diff --git a/goffice/graph/gog-theme.c b/goffice/graph/gog-theme.c
index 9b22607..7f64ebb 100644
--- a/goffice/graph/gog-theme.c
+++ b/goffice/graph/gog-theme.c
@@ -226,9 +226,9 @@ gog_theme_finalize (GObject *obj)
themes = g_slist_remove (themes, theme);
- g_free (theme->name); theme->name = NULL;
- g_free (theme->local_name); theme->local_name = NULL;
- g_free (theme->description); theme->description = NULL;
+ g_free (theme->name);
+ g_free (theme->local_name);
+ g_free (theme->description);
if (theme->elem_hash_by_role)
g_hash_table_destroy (theme->elem_hash_by_role);
if (theme->elem_hash_by_class)
@@ -241,6 +241,8 @@ gog_theme_finalize (GObject *obj)
g_object_unref (g_ptr_array_index (theme->palette, i));
g_ptr_array_free (theme->palette, TRUE);
}
+ if (theme->dcm)
+ g_object_unref (theme->dcm);
(parent_klass->finalize) (obj);
}
@@ -678,7 +680,8 @@ gog_theme_registry_get_theme_names (void)
/**************************************************************************/
-static void build_predefined_themes (void)
+static void
+build_predefined_themes (void)
{
GogTheme *theme;
GOStyle *style;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]