[gvfs/gnome-3-14] daemon: Don't abort if jobs != NULL when finalizing



commit 86a5d5749e4d45b785c46223b7e9ae0343057178
Author: Ross Lagerwall <rosslagerwall gmail com>
Date:   Sun Sep 28 21:52:36 2014 +0100

    daemon: Don't abort if jobs != NULL when finalizing
    
    Don't abort if there are outstanding jobs when finalizing.  This may
    happen if the backend is force unmounted.  Use a warning instead.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=710986

 daemon/gvfsdaemon.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/daemon/gvfsdaemon.c b/daemon/gvfsdaemon.c
index 4e624b8..0187223 100644
--- a/daemon/gvfsdaemon.c
+++ b/daemon/gvfsdaemon.c
@@ -147,7 +147,9 @@ g_vfs_daemon_finalize (GObject *object)
 
   daemon = G_VFS_DAEMON (object);
 
-  g_assert (daemon->jobs == NULL);
+  /* There may be some jobs outstanding if we've been force unmounted. */
+  if (daemon->jobs)
+    g_warning ("daemon->jobs != NULL when finalizing daemon!");
 
   if (daemon->name_watcher)
     g_bus_unwatch_name (daemon->name_watcher);


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