[gnome-flashback] logical-monitor: free the monitors list on finalize
- From: Alberts Muktupāvels <muktupavels src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-flashback] logical-monitor: free the monitors list on finalize
- Date: Fri, 20 Oct 2017 16:20:50 +0000 (UTC)
commit 82a4a5460d7909998676f32f80577a73b3cd8a4b
Author: Marco Trevisan (Treviño) <mail 3v1n0 net>
Date: Thu Oct 19 23:53:58 2017 -0500
logical-monitor: free the monitors list on finalize
https://bugzilla.gnome.org/show_bug.cgi?id=789227
backends/gf-logical-monitor.c | 17 +++++++++++++++++
1 files changed, 17 insertions(+), 0 deletions(-)
---
diff --git a/backends/gf-logical-monitor.c b/backends/gf-logical-monitor.c
index f54c205..b89dde0 100644
--- a/backends/gf-logical-monitor.c
+++ b/backends/gf-logical-monitor.c
@@ -71,8 +71,25 @@ derive_monitor_transform (GfMonitor *monitor)
}
static void
+gf_logical_monitor_finalize (GObject *object)
+{
+ GfLogicalMonitor *logical_monitor;
+
+ logical_monitor = GF_LOGICAL_MONITOR (object);
+
+ g_list_free (logical_monitor->monitors);
+
+ G_OBJECT_CLASS (gf_logical_monitor_parent_class)->finalize (object);
+}
+
+static void
gf_logical_monitor_class_init (GfLogicalMonitorClass *logical_monitor_class)
{
+ GObjectClass *object_class;
+
+ object_class = G_OBJECT_CLASS (logical_monitor_class);
+
+ object_class->finalize = gf_logical_monitor_finalize;
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]