[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[virt-tools-list] [PATCH 07/11] virt-viewer-app: unref the session on dispose



With this patch combined with the previous patches in this series, the
VirtViewerSession (finally) gets properly finalized on exit.

Signed-off-by: Hans de Goede <hdegoede redhat com>
---
 src/virt-viewer-app.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/src/virt-viewer-app.c b/src/virt-viewer-app.c
index 6fb83f6..2a66142 100644
--- a/src/virt-viewer-app.c
+++ b/src/virt-viewer-app.c
@@ -1231,6 +1231,11 @@ virt_viewer_app_dispose (GObject *object)
         g_object_unref(priv->container);
         priv->container = NULL;
     }
+
+    if (priv->session) {
+        g_object_unref(priv->session);
+        priv->session = NULL;
+    }
     g_free(priv->title);
 
     virt_viewer_app_free_connect_info(self);
-- 
1.7.7.6


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]