[gnome-photos] base-item: Make sure we unref the PrintOperation object



commit db0b1801419b5503b4657a1b827ee8de24377fe9
Author: Rafael Fonseca <r4f4rfs gmail com>
Date:   Tue Mar 15 10:25:18 2016 +0100

    base-item: Make sure we unref the PrintOperation object
    
    https://bugzilla.gnome.org/show_bug.cgi?id=763500

 src/photos-base-item.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/src/photos-base-item.c b/src/photos-base-item.c
index 726f9ba..74592fe 100644
--- a/src/photos-base-item.c
+++ b/src/photos-base-item.c
@@ -1456,7 +1456,7 @@ photos_base_item_print_load (GObject *source_object, GAsyncResult *res, gpointer
   PhotosBaseItem *self = PHOTOS_BASE_ITEM (source_object);
   GtkWindow *toplevel = GTK_WINDOW (user_data);
   GeglNode *node;
-  GtkPrintOperation *print_op;
+  GtkPrintOperation *print_op = NULL;
 
   node = photos_base_item_load_finish (self, res, NULL);
   if (node == NULL)
@@ -1478,6 +1478,7 @@ photos_base_item_print_load (GObject *source_object, GAsyncResult *res, gpointer
 
  out:
   g_clear_object (&node);
+  g_clear_object (&print_op);
   g_object_unref (toplevel);
 }
 


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