aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2012-07-01 01:11:12 -0700
committerZac Medico <zmedico@gentoo.org>2012-07-01 01:11:12 -0700
commite26ac28af7a6dc4cff2bf00737841d14dea669a5 (patch)
treeb9cfe9abb7a737d09f195b69e532b7d85eefd89f /pym/portage/dbapi/bintree.py
parentSupport FEATURES={downgrade,unmerge}-backup (diff)
downloadportage-e26ac28af7a6dc4cff2bf00737841d14dea669a5.tar.gz
portage-e26ac28af7a6dc4cff2bf00737841d14dea669a5.tar.bz2
portage-e26ac28af7a6dc4cff2bf00737841d14dea669a5.zip
Fix bugs in binarytree.invalids usage.
Diffstat (limited to 'pym/portage/dbapi/bintree.py')
-rw-r--r--pym/portage/dbapi/bintree.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/pym/portage/dbapi/bintree.py b/pym/portage/dbapi/bintree.py
index fb315729c..1048cc108 100644
--- a/pym/portage/dbapi/bintree.py
+++ b/pym/portage/dbapi/bintree.py
@@ -1312,6 +1312,8 @@ class binarytree(object):
"""Returns the URI to the Packages file for a given package."""
return self._pkgindex_uri.get(pkgname)
+
+
def gettbz2(self, pkgname):
"""Fetches the package from a remote site, if necessary. Attempts to
resume if the file appears to be partially downloaded."""
@@ -1319,7 +1321,7 @@ class binarytree(object):
tbz2name = os.path.basename(tbz2_path)
resume = False
if os.path.exists(tbz2_path):
- if (tbz2name not in self.invalids):
+ if tbz2name[:-5] not in self.invalids:
return
else:
resume = True