Merge lp://staging/~stgraber/upstart/upstart-tests-pty into lp://staging/upstart
Proposed by
Stéphane Graber
Status: | Merged |
---|---|
Merged at revision: | 1413 |
Proposed branch: | lp://staging/~stgraber/upstart/upstart-tests-pty |
Merge into: | lp://staging/upstart |
Diff against target: |
19 lines (+2/-1) 1 file modified
init/tests/test_job_process.c (+2/-1) |
To merge this branch: | bzr merge lp://staging/~stgraber/upstart/upstart-tests-pty |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
James Hunt | Approve | ||
Review via email: mp+140388@code.staging.launchpad.net |
Description of the change
This fixes our current PPA build hang.
PPA don't allow writting to /dev/tty (for some weird reason), so upstart
uses a pty instead. However the function setting up the pty was a bit wrong
as it was doing a waitpid on the child before starting the mainloop watching
for the output coming to the pty.
So as soon as the pty buffer was full, everything would hang.
This simply moves the mainloop start before the waitpid, fixing the hang.
To post a comment you must log in.
Good catch! LGTM - merged.