Patchwork [bitbake-devel,03/17] cooker: terminate each process when quitting recipe parsing

login
register
mail settings
Submitter Dongxiao Xu
Date March 21, 2012, 12:55 p.m.
Message ID <570fcedf96848b38ae13ff68e90d9a7987bfced7.1332334068.git.dongxiao.xu@intel.com>
Download mbox | patch
Permalink /patch/23979/
State New
Headers show

Comments

Dongxiao Xu - March 21, 2012, 12:55 p.m.
In some cases (e.x., Hob), users may quit the GUI when bitbake server
is doing the recipe parsing. In this case, we will see the Hob
command line hang and could not return to shell (Ctrl+C doesn't work).

The fix is to terminate the process when exiting the parsing.

This fixes [YOCTO #2142]

Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
---
 lib/bb/cooker.py |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

Patch

diff --git a/lib/bb/cooker.py b/lib/bb/cooker.py
index 1fd2c13..a000f72 100644
--- a/lib/bb/cooker.py
+++ b/lib/bb/cooker.py
@@ -1603,6 +1603,7 @@  class CookerParser(object):
 
             self.parser_quit.cancel_join_thread()
             for process in self.processes:
+                process.terminate()
                 self.parser_quit.put(None)
 
             self.jobs.cancel_join_thread()