summaryrefslogtreecommitdiffstats
path: root/Lib/subprocess.py
diff options
context:
space:
mode:
authorStefan Krah <stefan@bytereef.org>2010-07-19 14:20:53 (GMT)
committerStefan Krah <stefan@bytereef.org>2010-07-19 14:20:53 (GMT)
commit9542cc6eb594f5b1e26b9dfacd9f427f64b6019c (patch)
tree5394e4a0f76a9692175404e845af2abf36feed1b /Lib/subprocess.py
parentf4ebe2e8a0accd8ac2e47619e6d58a6171dd650b (diff)
downloadcpython-9542cc6eb594f5b1e26b9dfacd9f427f64b6019c.zip
cpython-9542cc6eb594f5b1e26b9dfacd9f427f64b6019c.tar.gz
cpython-9542cc6eb594f5b1e26b9dfacd9f427f64b6019c.tar.bz2
Issue #9265: Incorrect name passed as arg[0] when shell=True
and executable specified.
Diffstat (limited to 'Lib/subprocess.py')
-rw-r--r--Lib/subprocess.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/subprocess.py b/Lib/subprocess.py
index c2621ea..f8a6342 100644
--- a/Lib/subprocess.py
+++ b/Lib/subprocess.py
@@ -1073,6 +1073,8 @@ class Popen(object):
if shell:
args = ["/bin/sh", "-c"] + args
+ if executable:
+ args[0] = executable
if executable is None:
executable = args[0]