summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2007-01-04 03:23:12 +0000
committerZac Medico <zmedico@gentoo.org>2007-01-04 03:23:12 +0000
commit1554c6229999783fbf0a3f7d5303ea21d0e8ec3d (patch)
tree86edda3de32e771796e52290e54ffac86571e464
parent20df969c2cda9a0b524e3f18ec2a211be7a1722f (diff)
downloadportage-1554c6229999783fbf0a3f7d5303ea21d0e8ec3d.tar.gz
portage-1554c6229999783fbf0a3f7d5303ea21d0e8ec3d.tar.bz2
portage-1554c6229999783fbf0a3f7d5303ea21d0e8ec3d.zip
Make sure that myid is defined for the previous commit.
svn path=/main/trunk/; revision=5459
-rw-r--r--pym/getbinpkg.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/pym/getbinpkg.py b/pym/getbinpkg.py
index 058919bf1..6939e4840 100644
--- a/pym/getbinpkg.py
+++ b/pym/getbinpkg.py
@@ -522,6 +522,7 @@ def dir_get_metadata(baseurl, conn=None, chunk_size=3000, verbose=1, usingcache=
(x not in metadata[baseurl]["data"].keys())):
sys.stderr.write(yellow("x"))
metadata[baseurl]["modified"] = 1
+ myid = None
for retry in xrange(3):
try:
myid = file_get_metadata(
@@ -536,7 +537,7 @@ def dir_get_metadata(baseurl, conn=None, chunk_size=3000, verbose=1, usingcache=
conn, protocol, address, params, headers = create_conn(
baseurl)
- if myid[0]:
+ if myid and myid[0]:
metadata[baseurl]["data"][x] = make_metadata_dict(myid)
elif verbose:
sys.stderr.write(red("!!! Failed to retrieve metadata on: ")+str(x)+"\n")