diff --git a/bitbake/lib/bb/fetch2/__init__.py b/bitbake/lib/bb/fetch2/__init__.py index 6847873e7b..7524fa95a8 100644 --- a/bitbake/lib/bb/fetch2/__init__.py +++ b/bitbake/lib/bb/fetch2/__init__.py @@ -192,7 +192,7 @@ def uri_replace(ud, uri_find, uri_replace, d): if uri_find_decoded.index(i) == 2: basename = None if ud.mirrortarball: - basename = os.path.basename(ud.localpath) + basename = os.path.basename(ud.mirrortarball) elif ud.localpath: basename = os.path.basename(ud.localpath) if basename and result_decoded[loc].endswith("/"):