diff options
author | Gregory P. Smith <greg@krypto.org> | 2014-06-01 07:33:35 (GMT) |
---|---|---|
committer | Gregory P. Smith <greg@krypto.org> | 2014-06-01 07:33:35 (GMT) |
commit | 7be74cffbe96e9649a331260ba0fbf2c2b4a1de0 (patch) | |
tree | 9f450ebdc678eae1a2dc9ef67a43ce32684fbf33 /Lib | |
parent | d3e50be6d01ac5abb2df8608e75ee8ca5c9ed7f7 (diff) | |
download | cpython-7be74cffbe96e9649a331260ba0fbf2c2b4a1de0.zip cpython-7be74cffbe96e9649a331260ba0fbf2c2b4a1de0.tar.gz cpython-7be74cffbe96e9649a331260ba0fbf2c2b4a1de0.tar.bz2 |
Remove the obsolete MAXFD constant and Popen._close_fds() method.
They should have been removed years ago when removing the old pure
Python implementation from the file.
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/subprocess.py | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/Lib/subprocess.py b/Lib/subprocess.py index daa3e25..49aa6ab 100644 --- a/Lib/subprocess.py +++ b/Lib/subprocess.py @@ -469,10 +469,6 @@ if mswindows: __del__ = Close __str__ = __repr__ -try: - MAXFD = os.sysconf("SC_OPEN_MAX") -except: - MAXFD = 256 # This lists holds Popen instances for which the underlying process had not # exited at the time its __del__ method got called: those processes are wait()ed @@ -1335,16 +1331,6 @@ class Popen(object): errread, errwrite) - def _close_fds(self, fds_to_keep): - start_fd = 3 - for fd in sorted(fds_to_keep): - if fd >= start_fd: - os.closerange(start_fd, fd) - start_fd = fd + 1 - if start_fd <= MAXFD: - os.closerange(start_fd, MAXFD) - - def _execute_child(self, args, executable, preexec_fn, close_fds, pass_fds, cwd, env, startupinfo, creationflags, shell, |