[Python-checkins] cpython (merge 3.5 -> default): Issue #25764: Merge fix for root user from 3.5
martin.panter
python-checkins at python.org
Fri Dec 11 01:04:43 EST 2015
https://hg.python.org/cpython/rev/2f9541cab936
changeset: 99525:2f9541cab936
parent: 99524:360c1326d8d1
parent: 99523:fe844253cd44
user: Martin Panter <vadmium+py at gmail.com>
date: Fri Dec 11 05:42:26 2015 +0000
summary:
Issue #25764: Merge fix for root user from 3.5
files:
Lib/test/test_subprocess.py | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/Lib/test/test_subprocess.py b/Lib/test/test_subprocess.py
--- a/Lib/test/test_subprocess.py
+++ b/Lib/test/test_subprocess.py
@@ -1525,10 +1525,14 @@
[_, hard] = limits
setrlimit(RLIMIT_NPROC, (0, hard))
self.addCleanup(setrlimit, RLIMIT_NPROC, limits)
- # Forking should raise EAGAIN, translated to BlockingIOError
- with self.assertRaises(BlockingIOError):
+ try:
subprocess.call([sys.executable, '-c', ''],
preexec_fn=lambda: None)
+ except BlockingIOError:
+ # Forking should raise EAGAIN, translated to BlockingIOError
+ pass
+ else:
+ self.skipTest('RLIMIT_NPROC had no effect; probably superuser')
def test_args_string(self):
# args is a string
--
Repository URL: https://hg.python.org/cpython
More information about the Python-checkins
mailing list