summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristopher Larson <chris_larson@mentor.com>2015-12-10 23:57:23 +0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-01-08 12:08:47 +0000
commit022fe4481dc80121abb04e8a2b357722bc806475 (patch)
treea9d52f80246dfa8dd95b520db353b0100a309dd3
parentfca41cf073469493e9dada377fc42d4b084c45c9 (diff)
downloadbitbake-022fe4481dc80121abb04e8a2b357722bc806475.tar.gz
fetch: use orig localpath when calling orig method
When a mirror tarball is fetched, the original fetch method is called, which unpacks the mirror tarball. After the original method is called, it checks the localpath of the mirror tarball rather than the clone path, which isn't ideal, particularly if the mirror tarball was removed due to being out of date. We know the original fetch method will do what it needs to do to get its content in the form it needs from the mirror tarball, so we can use its localpath instead. Signed-off-by: Christopher Larson <chris_larson@mentor.com> Signed-off-by: Awais Belal <awais_belal@mentor.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--lib/bb/fetch2/__init__.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/bb/fetch2/__init__.py b/lib/bb/fetch2/__init__.py
index 288a1c8fd..a9c044b6a 100644
--- a/lib/bb/fetch2/__init__.py
+++ b/lib/bb/fetch2/__init__.py
@@ -955,7 +955,7 @@ def try_mirror_url(fetch, origud, ud, ld, check = False):
origud.method.download(origud, ld)
if hasattr(origud.method,"build_mirror_data"):
origud.method.build_mirror_data(origud, ld)
- return ud.localpath
+ return origud.localpath
# Otherwise the result is a local file:// and we symlink to it
if not os.path.exists(origud.localpath):
if os.path.islink(origud.localpath):