Skip to content

Commit

Permalink
Empty the multiprocessing queue before terminating it
Browse files Browse the repository at this point in the history
  • Loading branch information
screamerbg committed Aug 2, 2016
1 parent 31a59c9 commit a4c3469
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tools/toolchains/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -794,6 +794,9 @@ def compile_queue(self, queue, objects):
])
objects.append(result['object'])
except ToolException, err:
if p._taskqueue.queue:
p._taskqueue.queue.clear()
sleep(0.5)
p.terminate()
p.join()
raise ToolException(err)
Expand Down

0 comments on commit a4c3469

Please sign in to comment.