mirror of
https://github.com/python/cpython.git
synced 2025-08-29 21:25:01 +00:00
#2304: fix incorporating Eric Smith's .format suggestion and tested on Ubuntu as well as Windows
This commit is contained in:
parent
32cfedeb1c
commit
126c2960ca
2 changed files with 44 additions and 2 deletions
|
@ -853,7 +853,7 @@ class Popen(object):
|
|||
startupinfo.dwFlags |= _subprocess.STARTF_USESHOWWINDOW
|
||||
startupinfo.wShowWindow = _subprocess.SW_HIDE
|
||||
comspec = os.environ.get("COMSPEC", "cmd.exe")
|
||||
args = comspec + " /c " + args
|
||||
args = '{} /c "{}"'.format (comspec, args)
|
||||
if (_subprocess.GetVersion() >= 0x80000000 or
|
||||
os.path.basename(comspec).lower() == "command.com"):
|
||||
# Win9x, or using command.com on NT. We need to
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue