diff options
author | Chris Lumens <clumens@redhat.com> | 2007-04-03 19:32:20 +0000 |
---|---|---|
committer | Chris Lumens <clumens@redhat.com> | 2007-04-03 19:32:20 +0000 |
commit | b4341e70f7b613c961ef514bc5f0c0f1c1804f30 (patch) | |
tree | 8c551a16eda01fda08b8509f1a596f64ad6f3cd8 /yuminstall.py | |
parent | c97e83f381dc52bf88ddc3811c9e88b271dcab43 (diff) | |
download | anaconda-b4341e70f7b613c961ef514bc5f0c0f1c1804f30.tar.gz anaconda-b4341e70f7b613c961ef514bc5f0c0f1c1804f30.tar.xz anaconda-b4341e70f7b613c961ef514bc5f0c0f1c1804f30.zip |
Correctly detect if there are no more mirrors to try (#232639).
Diffstat (limited to 'yuminstall.py')
-rw-r--r-- | yuminstall.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/yuminstall.py b/yuminstall.py index 63c0a9c00..36d601877 100644 --- a/yuminstall.py +++ b/yuminstall.py @@ -613,8 +613,10 @@ class YumBackend(AnacondaBackend): def mirrorFailureCB (self, obj, *args, **kwargs): log.warning("Failed to get %s from mirror" % obj.url) - - if kwargs["grab"]._next >= len(kwargs["grab"].mirrors): + + # We don't increment the mirror index until after running this + # callback, so check if _next is one less. + if kwargs["grab"]._next == len(kwargs["grab"].mirrors) - 1: if self.method.currentMedia: if kwargs.has_key("tsInfo"): self.prevmedia = kwargs["tsInfo"].curmedia |