diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-06-20 12:38:53 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-08-21 11:35:07 +0100 |
commit | 4bfb54e0ba03bbb19511158bbe68c08782b76bea (patch) | |
tree | dc14661b3c79f418034be59c26c971b21184593b /bitbake/lib/bb | |
parent | 729b396b2160367f38443d1a64e6e8bbaffc1c35 (diff) | |
download | poky-4bfb54e0ba03bbb19511158bbe68c08782b76bea.tar.gz |
bitbake: fetch2: Only cache data if fn is set, its pointless caching it against a None value
(From Poky rev: c2df30bf6d1f8c263a38c45866936c1bf496ece5)
(Bitbake rev: f4b59cc6e1c3ddc168a1678ce39ff402ea1ff4cc)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb')
-rw-r--r-- | bitbake/lib/bb/fetch2/__init__.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/bitbake/lib/bb/fetch2/__init__.py b/bitbake/lib/bb/fetch2/__init__.py index a26f61eb42..2ae8185601 100644 --- a/bitbake/lib/bb/fetch2/__init__.py +++ b/bitbake/lib/bb/fetch2/__init__.py | |||
@@ -904,14 +904,14 @@ class Fetch(object): | |||
904 | self.ud = {} | 904 | self.ud = {} |
905 | 905 | ||
906 | fn = d.getVar('FILE', True) | 906 | fn = d.getVar('FILE', True) |
907 | if cache and fn in urldata_cache: | 907 | if cache and fn and fn in urldata_cache: |
908 | self.ud = urldata_cache[fn] | 908 | self.ud = urldata_cache[fn] |
909 | 909 | ||
910 | for url in urls: | 910 | for url in urls: |
911 | if url not in self.ud: | 911 | if url not in self.ud: |
912 | self.ud[url] = FetchData(url, d) | 912 | self.ud[url] = FetchData(url, d) |
913 | 913 | ||
914 | if cache: | 914 | if fn and cache: |
915 | urldata_cache[fn] = self.ud | 915 | urldata_cache[fn] = self.ud |
916 | 916 | ||
917 | def localpath(self, url): | 917 | def localpath(self, url): |