richardphibel / rpms / libdnf

Forked from rpms/libdnf 2 years ago
Clone
Blob Blame History Raw
From c04e8362708bbb7d14b7d9a9bdc8fd212af53c59 Mon Sep 17 00:00:00 2001
From: Jaroslav Mracek <jmracek@redhat.com>
Date: Fri, 15 Mar 2019 14:02:23 +0100
Subject: [PATCH] Set default to skip_if_unavailable=false (RhBug:1679509)

---
 libdnf/conf/ConfigRepo.cpp | 2 +-
 libdnf/dnf-repo.cpp        | 2 ++
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/libdnf/conf/ConfigRepo.cpp b/libdnf/conf/ConfigRepo.cpp
index e684940..43fe56b 100644
--- a/libdnf/conf/ConfigRepo.cpp
+++ b/libdnf/conf/ConfigRepo.cpp
@@ -71,7 +71,7 @@ class ConfigRepo::Impl {
     OptionChild<OptionString> sslclientkey{masterConfig.sslclientkey()};
     OptionChild<OptionBool> deltarpm{masterConfig.deltarpm()};
     OptionChild<OptionNumber<std::uint32_t> > deltarpm_percentage{masterConfig.deltarpm_percentage()};
-    OptionBool skip_if_unavailable{true};
+    OptionBool skip_if_unavailable{false};
     OptionString enabled_metadata{""};
     OptionEnum<std::string> failovermethod{"priority", {"priority", "roundrobin"}};
 };
diff --git a/libdnf/dnf-repo.cpp b/libdnf/dnf-repo.cpp
index dfe161d..34bbc8f 100644
--- a/libdnf/dnf-repo.cpp
+++ b/libdnf/dnf-repo.cpp
@@ -966,6 +966,8 @@ dnf_repo_set_keyfile_data(DnfRepo *repo, GError **error)
             priv->required = FALSE;
         else
             priv->required = TRUE;
+    } else {
+        priv->required = TRUE;
     }
 
     /* cost is optional */
--
libgit2 0.27.7