[gnome-photos] delete-item-job: Be robust against PhotosTrackerQueue failures



commit ae7fa55a7f3a3ec0a7e1e14da04aa0cba8a59b23
Author: Debarshi Ray <debarshir gnome org>
Date:   Sat Dec 28 12:02:29 2013 +0100

    delete-item-job: Be robust against PhotosTrackerQueue failures
    
    Fixes: https://bugzilla.gnome.org/704947

 src/photos-delete-item-job.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)
---
diff --git a/src/photos-delete-item-job.c b/src/photos-delete-item-job.c
index 5b1036c..92fa442 100644
--- a/src/photos-delete-item-job.c
+++ b/src/photos-delete-item-job.c
@@ -161,6 +161,13 @@ photos_delete_item_job_run (PhotosDeleteItemJob *self,
   PhotosDeleteItemJobPrivate *priv = self->priv;
   PhotosQuery *query;
 
+  if (G_UNLIKELY (priv->queue == NULL))
+    {
+      if (callback != NULL)
+        (*callback) (user_data);
+      return;
+    }
+
   priv->callback = callback;
   priv->user_data = user_data;
 


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