Open file handles leaking to child processes in remote (ssh) mode #202558
Labels
bug
Issue identified by VS Code Team member as probable bug
*duplicate
Issue identified as a duplicate of another issue(s)
server
ssh
Does this issue occur when all extensions are disabled?: Yes/No
Steps to Reproduce:
sleep 600
.ls -l /proc/<n>/fd
I see the following (slightly redacted) list of file handles open in the child process:
Those file handles should not be leaking into child processes like that. Such leakage can be problematic:
/proc/sys/fs/file-max
orulimit -n
tmux
session or anipython
server withnohup
).It would appear that at least some files aren't being opened with
O_CLOEXEC
. It's very rare that opening files withoutO_CLOEXEC
is a good idea in linux (Python has made this the default since 3.4 and I believe that in Windows you have to go pretty far out of the way to have a child inherit a file handle)The text was updated successfully, but these errors were encountered: