diff options
Diffstat (limited to 'bitbake/lib/bb/fetch/git.py')
-rw-r--r-- | bitbake/lib/bb/fetch/git.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/bitbake/lib/bb/fetch/git.py b/bitbake/lib/bb/fetch/git.py index 9a51ed1387..49c1cfe8f9 100644 --- a/bitbake/lib/bb/fetch/git.py +++ b/bitbake/lib/bb/fetch/git.py | |||
@@ -269,9 +269,9 @@ class Git(Fetch): | |||
269 | oldkey = self.generate_revision_key(url, ud, d, branch=False) | 269 | oldkey = self.generate_revision_key(url, ud, d, branch=False) |
270 | 270 | ||
271 | latest_rev = self._build_revision(url, ud, d) | 271 | latest_rev = self._build_revision(url, ud, d) |
272 | last_rev = localcounts[key + '_rev'] | 272 | last_rev = localcounts.get(key + '_rev') |
273 | if last_rev is None: | 273 | if last_rev is None: |
274 | last_rev = localcounts[oldkey + '_rev'] | 274 | last_rev = localcounts.get(oldkey + '_rev') |
275 | if last_rev is not None: | 275 | if last_rev is not None: |
276 | del localcounts[oldkey + '_rev'] | 276 | del localcounts[oldkey + '_rev'] |
277 | localcounts[key + '_rev'] = last_rev | 277 | localcounts[key + '_rev'] = last_rev |
@@ -281,9 +281,9 @@ class Git(Fetch): | |||
281 | if uselocalcount: | 281 | if uselocalcount: |
282 | count = Fetch.localcount_internal_helper(ud, d) | 282 | count = Fetch.localcount_internal_helper(ud, d) |
283 | if count is None: | 283 | if count is None: |
284 | count = localcounts[key + '_count'] | 284 | count = localcounts.get(key + '_count') |
285 | if count is None: | 285 | if count is None: |
286 | count = localcounts[oldkey + '_count'] | 286 | count = localcounts.get(oldkey + '_count') |
287 | if count is not None: | 287 | if count is not None: |
288 | del localcounts[oldkey + '_count'] | 288 | del localcounts[oldkey + '_count'] |
289 | localcounts[key + '_count'] = count | 289 | localcounts[key + '_count'] = count |