[gvfs/gnome-3-6] gphoto2: make sure to not call g_mutex_clear twice, causing a crash



commit 4c89512db9d745f155bb26216ed686bc9fc10f1c
Author: Michael Terry <michael terry canonical com>
Date:   Wed Oct 10 15:41:55 2012 -0400

    gphoto2: make sure to not call g_mutex_clear twice, causing a crash
    
    https://bugzilla.gnome.org/show_bug.cgi?id=685909
    (cherry picked from commit c90f496faeb3451819c1d96f24abeb0d66013ef4)

 daemon/gvfsbackendgphoto2.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/daemon/gvfsbackendgphoto2.c b/daemon/gvfsbackendgphoto2.c
index 5f0b435..4fe76f7 100644
--- a/daemon/gvfsbackendgphoto2.c
+++ b/daemon/gvfsbackendgphoto2.c
@@ -621,7 +621,6 @@ release_device (GVfsBackendGphoto2 *gphoto2_backend)
   g_list_free (gphoto2_backend->file_monitor_proxies);
   gphoto2_backend->file_monitor_proxies = NULL;
 
-  g_mutex_clear (&gphoto2_backend->lock);
   gphoto2_backend->capacity = -1;
   gphoto2_backend->free_space = -1;
 }
@@ -636,6 +635,7 @@ g_vfs_backend_gphoto2_finalize (GObject *object)
   DEBUG ("finalizing %p", object);
 
   release_device (gphoto2_backend);
+  g_mutex_clear (&gphoto2_backend->lock);
 
   if (G_OBJECT_CLASS (g_vfs_backend_gphoto2_parent_class)->finalize)
     (*G_OBJECT_CLASS (g_vfs_backend_gphoto2_parent_class)->finalize) (object);



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