summaryrefslogtreecommitdiffstats
path: root/lib/bb/command.py
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2013-08-26 12:41:03 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2013-08-26 13:43:43 +0100
commit552b8935dd2f9f11e8d5c08a597a7e966b891480 (patch)
tree35a1ba1a60fa6fbbb9293df40b3d3431e2710911 /lib/bb/command.py
parent9c91948e10df278dad4832487fa56888cd58d187 (diff)
downloadbitbake-552b8935dd2f9f11e8d5c08a597a7e966b891480.tar.gz
command.py: Call updateCache for all states != running
updateCache handles the logic for shutting down the parsing so we need to call it for all cases when we're not running. This fixes hangs if Ctrl+C is pressed during parsing. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'lib/bb/command.py')
-rw-r--r--lib/bb/command.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/bb/command.py b/lib/bb/command.py
index bdf1c3663..3527ad03c 100644
--- a/lib/bb/command.py
+++ b/lib/bb/command.py
@@ -90,8 +90,7 @@ class Command:
(command, options) = self.currentAsyncCommand
commandmethod = getattr(CommandsAsync, command)
needcache = getattr( commandmethod, "needcache" )
- if (needcache and self.cooker.state in
- (bb.cooker.state.initial, bb.cooker.state.parsing)):
+ if needcache and self.cooker.state != bb.cooker.state.running:
self.cooker.updateCache()
return True
else: