[gtk+] places view: Spew less warnings



commit 6a4e4a9fe8ffb4b4acfbbb4d382278a5a22fdfb0
Author: Matthias Clasen <mclasen redhat com>
Date:   Wed Sep 2 01:28:57 2015 -0400

    places view: Spew less warnings
    
    When running the testsuite with a local gvfs, we get a 'not supported'
    error here, and the g_warning makes the test fail. Avoid that.

 gtk/gtkplacesview.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/gtk/gtkplacesview.c b/gtk/gtkplacesview.c
index fcb35b8..a2a8395 100644
--- a/gtk/gtkplacesview.c
+++ b/gtk/gtkplacesview.c
@@ -1002,7 +1002,8 @@ network_enumeration_finished (GObject      *source_object,
 
   if (error)
     {
-      if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED))
+      if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED) &&
+          !g_error_matches (error, G_IO_ERROR, G_IO_ERROR_NOT_SUPPORTED))
         g_warning ("Failed to fetch network locations: %s", error->message);
 
       g_clear_error (&error);


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