summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb
diff options
context:
space:
mode:
Diffstat (limited to 'bitbake/lib/bb')
-rw-r--r--bitbake/lib/bb/runqueue.py21
1 files changed, 14 insertions, 7 deletions
diff --git a/bitbake/lib/bb/runqueue.py b/bitbake/lib/bb/runqueue.py
index 967e944963..7d3e91a743 100644
--- a/bitbake/lib/bb/runqueue.py
+++ b/bitbake/lib/bb/runqueue.py
@@ -900,8 +900,11 @@ class RunQueue:
900 if not worker: 900 if not worker:
901 return 901 return
902 logger.debug(1, "Teardown for bitbake-worker") 902 logger.debug(1, "Teardown for bitbake-worker")
903 worker.stdin.write("<quit></quit>") 903 try:
904 worker.stdin.flush() 904 worker.stdin.write("<quit></quit>")
905 worker.stdin.flush()
906 except IOError:
907 pass
905 while worker.returncode is None: 908 while worker.returncode is None:
906 workerpipe.read() 909 workerpipe.read()
907 worker.poll() 910 worker.poll()
@@ -1275,11 +1278,15 @@ class RunQueueExecute:
1275 1278
1276 def finish_now(self): 1279 def finish_now(self):
1277 1280
1278 self.rq.worker.stdin.write("<finishnow></finishnow>") 1281 for worker in [self.rq.worker, self.rq.fakeworker]:
1279 self.rq.worker.stdin.flush() 1282 if not worker:
1280 if self.rq.fakeworker: 1283 continue
1281 self.rq.fakeworker.stdin.write("<finishnow></finishnow>") 1284 try:
1282 self.rq.fakeworker.stdin.flush() 1285 worker.stdin.write("<finishnow></finishnow>")
1286 worker.stdin.flush()
1287 except IOError:
1288 # worker must have died?
1289 pass
1283 1290
1284 if len(self.failed_fnids) != 0: 1291 if len(self.failed_fnids) != 0:
1285 self.rq.state = runQueueFailed 1292 self.rq.state = runQueueFailed