Child processes inherit all file descriptors #5897
Labels
bug
Issues that relate to unexpected/unwanted behavior. Don't use for PRs.
comp: sclang
sclang C++ implementation (primitives, etc.). for changes to class lib use "comp: class library"
comp: scsynth
comp: supernova
By default, a child process created with
fork
inherits all open file descriptors (including all open sockets), except for those that have theFD_CLOEXEC
flag set. sclang and scsynth should really set theFD_CLOEXEC
on all sockets that are bound to a specific port number, otherwise a lingering child process might occupy certain ports, such as the lang port or scsynth port.Usually, this is not a problem, but some UGens (e.g.
VSTPlugin
) may internally create child processes. This is particularly bad if the child processes becomes a deamon or zombie process because it may block ports indefinitely. (This once happened to me with a VST plugin on a macOS.)The text was updated successfully, but these errors were encountered: