diff options
Diffstat (limited to 'Lib/os.py')
-rw-r--r-- | Lib/os.py | 8 |
1 files changed, 2 insertions, 6 deletions
@@ -864,12 +864,8 @@ if _exists("fork") and not _exists("spawnv") and _exists("execv"): wpid, sts = waitpid(pid, 0) if WIFSTOPPED(sts): continue - elif WIFSIGNALED(sts): - return -WTERMSIG(sts) - elif WIFEXITED(sts): - return WEXITSTATUS(sts) - else: - raise OSError("Not stopped, signaled or exited???") + + return waitstatus_to_exitcode(sts) def spawnv(mode, file, args): """spawnv(mode, file, args) -> integer |