[gnome-software] shell: Ignore G_IO_ERROR_CANCELLED errors



commit 3ae82526db5dab413a363c229f3ca8c661c496b8
Author: Philip Withnall <withnall endlessm com>
Date:   Wed Oct 2 15:21:24 2019 +0100

    shell: Ignore G_IO_ERROR_CANCELLED errors
    
    Just as we ignore `GS_PLUGIN_ERROR_CANCELLED` errors, ignore
    `G_IO_ERROR_CANCELLED` errors.
    
    Realistically, we are never going to manage to find every call site
    which could return `G_IO_ERROR_CANCELLED` and convert all of those
    errors to `GS_PLUGIN_ERROR_CANCELLED` on an ongoing basis.
    
    Signed-off-by: Philip Withnall <withnall endlessm com>

 src/gs-shell.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
---
diff --git a/src/gs-shell.c b/src/gs-shell.c
index eab11df1..918b794f 100644
--- a/src/gs-shell.c
+++ b/src/gs-shell.c
@@ -1801,7 +1801,10 @@ gs_shell_rescan_events (GsShell *shell)
                        if (error != NULL &&
                            !g_error_matches (error,
                                              GS_PLUGIN_ERROR,
-                                             GS_PLUGIN_ERROR_CANCELLED)) {
+                                             GS_PLUGIN_ERROR_CANCELLED) &&
+                           !g_error_matches (error,
+                                             G_IO_ERROR,
+                                             G_IO_ERROR_CANCELLED)) {
                                g_warning ("not handling error %s for action %s: %s",
                                           gs_plugin_error_to_string (error->code),
                                           gs_plugin_action_to_string (action),


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