• Gregory P. Smith's avatar
    Don't restrict ourselves to a "max" fd when closing fds before exec() · d4dcb702
    Gregory P. Smith authored
    when we have a way to get an actual list of all open fds from the OS.
    
    Fixes issue #21618: The subprocess module would ignore fds that were
    inherited by the calling process and already higher than POSIX resource
    limits would otherwise allow.  On systems with a functioning /proc/self/fd
    or /dev/fd interface the max is now ignored and all fds are closed.
    d4dcb702
test_subprocess.py 101 KB