summaryrefslogtreecommitdiffstats
path: root/yuminstall.py
diff options
context:
space:
mode:
authorChris Lumens <clumens@redhat.com>2009-06-01 16:23:43 -0400
committerChris Lumens <clumens@redhat.com>2009-06-01 16:23:43 -0400
commit59c3843f3a37eda3709cce2a1208385a6d968397 (patch)
treeaf8363d5996ce240ea08c1c6d54b098cb56a13a4 /yuminstall.py
parent3c6386ccc8f8aaaa2a3edb88f3a1aed4910b8d6f (diff)
downloadanaconda-59c3843f3a37eda3709cce2a1208385a6d968397.tar.gz
anaconda-59c3843f3a37eda3709cce2a1208385a6d968397.tar.xz
anaconda-59c3843f3a37eda3709cce2a1208385a6d968397.zip
Fix an error when editing an unreachable repo (#503454).
In certain cases, calling getRepo on "InstallationRepo" causes a RepoError. When we catch that, we don't set the repo value to anything, so a traceback results. Instead we need to fix the fix for creating a new repo.
Diffstat (limited to 'yuminstall.py')
-rw-r--r--yuminstall.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/yuminstall.py b/yuminstall.py
index e7f1d915d..34e3c1859 100644
--- a/yuminstall.py
+++ b/yuminstall.py
@@ -473,8 +473,9 @@ class AnacondaYum(YumSorter):
repo.baseurl = uri
except RepoError:
replace = False
- else:
- # If there was an error finding the "base" repo, create a new one now.
+
+ # If there was an error finding the "base" repo, create a new one now.
+ if not replace:
repo = AnacondaYumRepo("anaconda-%s-%s" % (rid, productStamp))
repo.baseurl = uri