From 613e3aa4aaae663c73ea9e7804167602f7353237 Mon Sep 17 00:00:00 2001 From: Otavio Pontes Date: Tue, 23 Jul 2019 10:13:21 -0700 Subject: [PATCH] mirror: On unset, always reload default values If you run: $ swupd mirror --unset -u sample We should print the default URL and not 'sample' Signed-off-by: Otavio Pontes --- src/mirror.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mirror.c b/src/mirror.c index 74e865c2..dce02287 100644 --- a/src/mirror.c +++ b/src/mirror.c @@ -114,6 +114,7 @@ static int unset_mirror_url() goto out; } +out: /* we need to also unset the mirror urls from the cache and set it to * the central version */ free_string(&globals.version_url); @@ -121,7 +122,6 @@ static int unset_mirror_url() set_default_version_url(); set_default_content_url(); get_latest_version(""); -out: free_string(&content_path); free_string(&version_path); return ret;