summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bitbake/lib/bb/fetch2/__init__.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/bitbake/lib/bb/fetch2/__init__.py b/bitbake/lib/bb/fetch2/__init__.py
index 324eef28a7..73ac73a112 100644
--- a/bitbake/lib/bb/fetch2/__init__.py
+++ b/bitbake/lib/bb/fetch2/__init__.py
@@ -210,8 +210,10 @@ def uri_replace(ud, uri_find, uri_replace, d):
210 if basename and not result_decoded[loc].endswith(basename): 210 if basename and not result_decoded[loc].endswith(basename):
211 result_decoded[loc] = os.path.join(result_decoded[loc], basename) 211 result_decoded[loc] = os.path.join(result_decoded[loc], basename)
212 else: 212 else:
213 return ud.url 213 return None
214 result = encodeurl(result_decoded) 214 result = encodeurl(result_decoded)
215 if result == ud.url:
216 return None
215 logger.debug(2, "For url %s returning %s" % (ud.url, result)) 217 logger.debug(2, "For url %s returning %s" % (ud.url, result))
216 return result 218 return result
217 219
@@ -477,7 +479,7 @@ def try_mirrors(d, origud, mirrors, check = False):
477 except ValueError: 479 except ValueError:
478 continue 480 continue
479 newuri = uri_replace(origud, find, replace, ld) 481 newuri = uri_replace(origud, find, replace, ld)
480 if newuri == origud.url: 482 if not newuri:
481 continue 483 continue
482 try: 484 try:
483 ud = FetchData(newuri, ld) 485 ud = FetchData(newuri, ld)