13 14__slots__=("pid",)+ \ 15("_dummy_pipe_fd","_files","_reg_id") 16 17# This is how much time we allow for waitpid to succeed after 18# we've sent a kill signal to our subprocess. 19_cancel_timeout=1000# 1 second 20

141"""142 Set the returncode in a manner compatible with143 subprocess.Popen.returncode: A negative value -N indicates144 that the child was terminated by signal N (Unix only).145 """146self._unregister()147148pid,status=wait_retval149150ifos.WIFSIGNALED(status):151retval=-os.WTERMSIG(status)152else:153retval=os.WEXITSTATUS(status)154155self.returncode=retval