diff options
author | Richard Purdie <rpurdie@linux.intel.com> | 2010-09-07 23:54:15 +0100 |
---|---|---|
committer | Richard Purdie <rpurdie@linux.intel.com> | 2010-09-07 23:54:15 +0100 |
commit | 7b580b488cb60ce4166ef2539496e83385779aa7 (patch) | |
tree | ad8533d33ea5382381c091448eabcc033c67373f /bitbake/bin | |
parent | 7ef65593aa45da08cb15e8fa76491de4aba5b4b3 (diff) | |
download | poky-7b580b488cb60ce4166ef2539496e83385779aa7.tar.gz |
bitbake/bitbake-runtask: Ensure signals to the parent don't pass to the children directly
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'bitbake/bin')
-rwxr-xr-x | bitbake/bin/bitbake-runtask | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/bitbake/bin/bitbake-runtask b/bitbake/bin/bitbake-runtask index dee25cdf27..cd033d1590 100755 --- a/bitbake/bin/bitbake-runtask +++ b/bitbake/bin/bitbake-runtask | |||
@@ -47,6 +47,13 @@ os.dup2(sys.stderr.fileno(), sys.stdout.fileno()) | |||
47 | #os.dup2(newso.fileno(), sys.stdout.fileno()) | 47 | #os.dup2(newso.fileno(), sys.stdout.fileno()) |
48 | #os.dup2(newso.fileno(), sys.stderr.fileno()) | 48 | #os.dup2(newso.fileno(), sys.stderr.fileno()) |
49 | 49 | ||
50 | # Don't read from stdin from the parent | ||
51 | si = file("/dev/null", 'r') | ||
52 | os.dup2(si.fileno( ), sys.stdin.fileno( )) | ||
53 | |||
54 | # We don't want to see signals to our parent, e.g. Ctrl+C | ||
55 | os.setpgrp() | ||
56 | |||
50 | # Save out the PID so that the event can include it the | 57 | # Save out the PID so that the event can include it the |
51 | # events | 58 | # events |
52 | bb.event.worker_pid = os.getpid() | 59 | bb.event.worker_pid = os.getpid() |