[gnome-packagekit/gnome-2-28] trivial: Fix critical warning when finalizing a GpkSession



commit a8c785d7ecc47ae0975658722fef2d0bb6c8bdea
Author: Richard Hughes <richard hughsie com>
Date:   Wed Oct 26 16:59:20 2016 +0100

    trivial: Fix critical warning when finalizing a GpkSession

 src/gpk-session.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/src/gpk-session.c b/src/gpk-session.c
index 29a80e7..9714603 100644
--- a/src/gpk-session.c
+++ b/src/gpk-session.c
@@ -481,8 +481,9 @@ gpk_session_finalize (GObject *object)
 
        g_object_unref (session->priv->proxy);
        g_object_unref (session->priv->proxy_presence);
-       g_object_unref (session->priv->proxy_client_private);
        g_object_unref (session->priv->proxy_prop);
+       if (session->priv->proxy_client_private != NULL)
+               g_object_unref (session->priv->proxy_client_private);
 
        G_OBJECT_CLASS (gpk_session_parent_class)->finalize (object);
 }


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