diff options
author | Peter Astrand <astrand@lysator.liu.se> | 2004-11-07 14:30:34 (GMT) |
---|---|---|
committer | Peter Astrand <astrand@lysator.liu.se> | 2004-11-07 14:30:34 (GMT) |
commit | c1d6536d60c39475895fb8691f81510393b9737b (patch) | |
tree | ee298865f6cc3e0cdc8ea39bdc6c613475f468e5 /PC | |
parent | 80961f3ca90ab48470fad8bb2310f19896ec9b7b (diff) | |
download | cpython-c1d6536d60c39475895fb8691f81510393b9737b.zip cpython-c1d6536d60c39475895fb8691f81510393b9737b.tar.gz cpython-c1d6536d60c39475895fb8691f81510393b9737b.tar.bz2 |
When using shell=True on Windows, don't display a shell window by default. Fixes #1057061.
Diffstat (limited to 'PC')
-rw-r--r-- | PC/_subprocess.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/PC/_subprocess.c b/PC/_subprocess.c index 34073c6..61544c3 100644 --- a/PC/_subprocess.c +++ b/PC/_subprocess.c @@ -377,6 +377,7 @@ sp_CreateProcess(PyObject* self, PyObject* args) /* note: we only support a small subset of all SI attributes */ si.dwFlags = getint(startup_info, "dwFlags"); + si.wShowWindow = getint(startup_info, "wShowWindow"); si.hStdInput = gethandle(startup_info, "hStdInput"); si.hStdOutput = gethandle(startup_info, "hStdOutput"); si.hStdError = gethandle(startup_info, "hStdError"); @@ -530,6 +531,8 @@ init_subprocess() defint(d, "STD_ERROR_HANDLE", STD_ERROR_HANDLE); defint(d, "DUPLICATE_SAME_ACCESS", DUPLICATE_SAME_ACCESS); defint(d, "STARTF_USESTDHANDLES", STARTF_USESTDHANDLES); + defint(d, "STARTF_USESHOWWINDOW", STARTF_USESHOWWINDOW); + defint(d, "SW_HIDE", SW_HIDE); defint(d, "INFINITE", INFINITE); defint(d, "WAIT_OBJECT_0", WAIT_OBJECT_0); defint(d, "CREATE_NEW_CONSOLE", CREATE_NEW_CONSOLE); |