summaryrefslogtreecommitdiffstats
path: root/Lib/popen2.py
diff options
context:
space:
mode:
authorPeter Astrand <astrand@lysator.liu.se>2006-06-22 20:21:26 (GMT)
committerPeter Astrand <astrand@lysator.liu.se>2006-06-22 20:21:26 (GMT)
commitff355f1adaa423c143c169221bd4a80775adf8bb (patch)
tree2c9a7a74ff9201d25e60c720fcf59a830eb27006 /Lib/popen2.py
parentd6b2430b7a99110119743b8529b66c39d1fed722 (diff)
downloadcpython-ff355f1adaa423c143c169221bd4a80775adf8bb.zip
cpython-ff355f1adaa423c143c169221bd4a80775adf8bb.tar.gz
cpython-ff355f1adaa423c143c169221bd4a80775adf8bb.tar.bz2
Applied patch #1506758: Prevent MemoryErrors with large MAXFD.
Diffstat (limited to 'Lib/popen2.py')
-rw-r--r--Lib/popen2.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/popen2.py b/Lib/popen2.py
index b966d4c..6f56a92 100644
--- a/Lib/popen2.py
+++ b/Lib/popen2.py
@@ -79,7 +79,7 @@ class Popen3:
def _run_child(self, cmd):
if isinstance(cmd, basestring):
cmd = ['/bin/sh', '-c', cmd]
- for i in range(3, MAXFD):
+ for i in xrange(3, MAXFD):
try:
os.close(i)
except OSError: