pty.spawn() now returns the child process status as returned by os.waitpid().

Addresses the remaining feature request from issue #2489.
This commit is contained in:
Gregory P. Smith 2012-09-29 12:41:03 -07:00
parent b32d5912d2
commit 0f21adf799
4 changed files with 12 additions and 0 deletions

View file

@ -178,3 +178,4 @@ def spawn(argv, master_read=_read, stdin_read=_read):
tty.tcsetattr(STDIN_FILENO, tty.TCSAFLUSH, mode)
os.close(master_fd)
return os.waitpid(pid, 0)[1]