[gimp] plug-ins: actually return FALSE if mount_enclosing_volume() fails



commit 04b01c3a256a5162db68095a1e65f6c5e17b3fd3
Author: Michael Natterer <mitch gimp org>
Date:   Thu Apr 1 21:15:19 2010 +0200

    plug-ins: actually return FALSE if mount_enclosing_volume() fails

 plug-ins/file-uri/uri-backend-gvfs.c |    7 +++----
 1 files changed, 3 insertions(+), 4 deletions(-)
---
diff --git a/plug-ins/file-uri/uri-backend-gvfs.c b/plug-ins/file-uri/uri-backend-gvfs.c
index 55cfb78..aba15a9 100644
--- a/plug-ins/file-uri/uri-backend-gvfs.c
+++ b/plug-ins/file-uri/uri-backend-gvfs.c
@@ -157,10 +157,9 @@ uri_backend_map_image (const gchar  *uri,
 
       if (! mount_enclosing_volume (file, &error))
         {
-
-          if (error->domain == G_IO_ERROR   &&
-              error->code   == G_IO_ERROR_ALREADY_MOUNTED)
-            success = TRUE;
+          if (error->domain != G_IO_ERROR ||
+              error->code   != G_IO_ERROR_ALREADY_MOUNTED)
+            success = FALSE;
 
           g_error_free (error);
         }



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