[gimp] app: don't leak the property keys hash tables of duplicated Gegl paramspecs
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] app: don't leak the property keys hash tables of duplicated Gegl paramspecs
- Date: Fri, 20 Jun 2014 07:04:39 +0000 (UTC)
commit f04ec31478561bd48555f8b97ea5f3d71f52dee2
Author: Michael Natterer <mitch gimp org>
Date: Fri Jun 20 09:00:46 2014 +0200
app: don't leak the property keys hash tables of duplicated Gegl paramspecs
This leak never happened because the duplicates are currently never
freed.
app/core/gimpparamspecs-duplicate.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/app/core/gimpparamspecs-duplicate.c b/app/core/gimpparamspecs-duplicate.c
index b9b271a..10671cd 100644
--- a/app/core/gimpparamspecs-duplicate.c
+++ b/app/core/gimpparamspecs-duplicate.c
@@ -264,7 +264,8 @@ gimp_param_spec_duplicate (GParamSpec *pspec)
GHashTable *keys = g_param_spec_get_qdata (pspec, quark);
if (keys)
- g_param_spec_set_qdata (copy, quark, g_hash_table_ref (keys));
+ g_param_spec_set_qdata_full (copy, quark, g_hash_table_ref (keys),
+ (GDestroyNotify) g_hash_table_unref);
}
return copy;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]