[dconf/wip/reorg] dconf source abstraction: don't leak the GVDBs
- From: Ryan Lortie <ryanl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [dconf/wip/reorg] dconf source abstraction: don't leak the GVDBs
- Date: Fri, 6 Jul 2012 04:21:48 +0000 (UTC)
commit 197c3bb81ca13bebc1fdf757f887455e588e3785
Author: Ryan Lortie <desrt desrt ca>
Date: Thu Jul 5 23:40:19 2012 -0400
dconf source abstraction: don't leak the GVDBs
On finalize, the GVDBs associated with a source weren't being freed.
This means that freeing a DConfClient (or any other DConfEngine user)
would result in leaking of GVDBs.
engine/dconf-engine-source.c | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/engine/dconf-engine-source.c b/engine/dconf-engine-source.c
index 48cf35c..45ec455 100644
--- a/engine/dconf-engine-source.c
+++ b/engine/dconf-engine-source.c
@@ -27,6 +27,12 @@
void
dconf_engine_source_free (DConfEngineSource *source)
{
+ if (source->values)
+ gvdb_table_unref (source->values);
+
+ if (source->locks)
+ gvdb_table_unref (source->locks);
+
source->vtable->finalize (source);
g_free (source->name);
g_free (source);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]