[goffice] Plugins: fix leaks.
- From: Morten Welinder <mortenw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [goffice] Plugins: fix leaks.
- Date: Tue, 1 Dec 2015 22:37:11 +0000 (UTC)
commit f9fd6579023bbba6f6ccee3b9e650c7ed1b0cc93
Author: Morten Welinder <terra gnome org>
Date: Tue Dec 1 17:37:38 2015 -0500
Plugins: fix leaks.
ChangeLog | 4 ++++
NEWS | 3 +++
goffice/app/go-plugin.c | 5 +++++
3 files changed, 12 insertions(+), 0 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 76b4a8c..f469bb0 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2015-12-01 Morten Welinder <terra gnome org>
+
+ * goffice/app/go-plugin.c (go_plugin_read): Plug leak.
+
2015-09-20 Morten Welinder <terra gnome org>
* configure.ac: Post-release bump.
diff --git a/NEWS b/NEWS
index 43df960..2edf834 100644
--- a/NEWS
+++ b/NEWS
@@ -1,5 +1,8 @@
goffice 0.10.25:
+Morten:
+ * Plug leaks.
+
--------------------------------------------------------------------------
goffice 0.10.24:
diff --git a/goffice/app/go-plugin.c b/goffice/app/go-plugin.c
index 453f88b..94c9c39 100644
--- a/goffice/app/go-plugin.c
+++ b/goffice/app/go-plugin.c
@@ -841,6 +841,7 @@ go_plugin_read (GOPlugin *plugin, gchar const *dir_name, GOErrorInfo **ret_error
GO_SLIST_PREPEND (dependency_list, dep);
}
} else {
+ g_free (loader_id);
loader_id = NULL;
loader_attrs = NULL;
}
@@ -865,6 +866,7 @@ go_plugin_read (GOPlugin *plugin, gchar const *dir_name, GOErrorInfo **ret_error
plugin->loader_attrs = loader_attrs;
plugin->loader = NULL;
plugin->services = go_plugin_read_service_list (plugin, tree, &services_error);
+ loader_attrs = NULL;
if (services_error != NULL) {
*ret_error = go_error_info_new_printf (
@@ -906,6 +908,9 @@ go_plugin_read (GOPlugin *plugin, gchar const *dir_name, GOErrorInfo **ret_error
}
g_free (file_name);
xmlFreeDoc (doc);
+
+ if (loader_attrs)
+ g_hash_table_destroy (loader_attrs);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]