[gnome-software: 6/9] fedora-pkgdb: Ignore GS_DOWNLOAD_ERROR_NOT_MODIFIED




commit 5832f72004ab30bd1c4bf430d3eb54f849c6b3fd
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date:   Mon Sep 12 14:10:02 2022 -0300

    fedora-pkgdb: Ignore GS_DOWNLOAD_ERROR_NOT_MODIFIED
    
    That means we have the most recent file already, which is an error
    that can safely be ignored.

 plugins/fedora-pkgdb-collections/gs-plugin-fedora-pkgdb-collections.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/plugins/fedora-pkgdb-collections/gs-plugin-fedora-pkgdb-collections.c 
b/plugins/fedora-pkgdb-collections/gs-plugin-fedora-pkgdb-collections.c
index 1a06d8832..1f788caae 100644
--- a/plugins/fedora-pkgdb-collections/gs-plugin-fedora-pkgdb-collections.c
+++ b/plugins/fedora-pkgdb-collections/gs-plugin-fedora-pkgdb-collections.c
@@ -278,7 +278,8 @@ download_cb (GObject      *source_object,
        GsPluginFedoraPkgdbCollections *self = g_task_get_source_object (task);
        g_autoptr(GError) local_error = NULL;
 
-       if (!gs_download_file_finish (soup_session, result, &local_error)) {
+       if (!gs_download_file_finish (soup_session, result, &local_error) &&
+           !g_error_matches (local_error, GS_DOWNLOAD_ERROR, GS_DOWNLOAD_ERROR_NOT_MODIFIED)) {
                g_autoptr(GError) wrapped_error = NULL;
 
                /* Wrap in a GsPluginError. */


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