From 9fc0204ad78b998e589d2f232eceda5e018584d6 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Thu, 10 Jan 2013 01:17:46 -0800 Subject: [PATCH] FetchTask: avoid possible duplicate URI --- pym/portage/_emirrordist/FetchTask.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/pym/portage/_emirrordist/FetchTask.py b/pym/portage/_emirrordist/FetchTask.py index 50e424289..107db56d4 100644 --- a/pym/portage/_emirrordist/FetchTask.py +++ b/pym/portage/_emirrordist/FetchTask.py @@ -255,8 +255,10 @@ class FetchTask(CompositeTask): if uri not in self._tried_uris: return uri - if self._primaryuri_stack: - return self._primaryuri_stack.pop() + while self._primaryuri_stack: + uri = self._primaryuri_stack.pop() + if uri not in self._tried_uris: + return uri return None -- 2.26.2