Close tty_fd in master on fork() rather than on close()
This commit is contained in:
parent
8998970adc
commit
6a101c51d2
1 changed files with 3 additions and 0 deletions
|
|
@ -463,6 +463,9 @@ def fork(self, free_non_child_resources: Callable[[], None]) -> None:
|
|||
if self.pid > 0:
|
||||
# master process
|
||||
os.close(w)
|
||||
if self.tty_fd > -1:
|
||||
os.close(self.tty_fd)
|
||||
self.tty_fd = -1
|
||||
if self.stdin > -1:
|
||||
os.close(self.stdin)
|
||||
self.stdin = -1
|
||||
|
|
|
|||
Loading…
Reference in a new issue