[Python-checkins] bpo-32560: inherit the py launcher's STARTUPINFO (GH-9000)

Miss Islington (bot) webhook-mailer at python.org
Sat Feb 2 14:38:19 EST 2019


https://github.com/python/cpython/commit/04b2a5eedac7ac0fecdafce1bda1028ee55e2aac
commit: 04b2a5eedac7ac0fecdafce1bda1028ee55e2aac
branch: 3.7
author: Miss Islington (bot) <31488909+miss-islington at users.noreply.github.com>
committer: GitHub <noreply at github.com>
date: 2019-02-02T11:38:16-08:00
summary:

bpo-32560: inherit the py launcher's STARTUPINFO (GH-9000)


https://bugs.python.org/issue32560
(cherry picked from commit cb0904762681031edc50f9d7d7ef48cffcf96d9a)

Co-authored-by: Shiva Saxena <shivasaxena911 at gmail.com>

files:
A Misc/NEWS.d/next/Windows/2019-02-02-11-02-44.bpo-32560.I5WAGW.rst
M PC/launcher.c

diff --git a/Misc/NEWS.d/next/Windows/2019-02-02-11-02-44.bpo-32560.I5WAGW.rst b/Misc/NEWS.d/next/Windows/2019-02-02-11-02-44.bpo-32560.I5WAGW.rst
new file mode 100644
index 000000000000..bf2bf113e24c
--- /dev/null
+++ b/Misc/NEWS.d/next/Windows/2019-02-02-11-02-44.bpo-32560.I5WAGW.rst
@@ -0,0 +1,2 @@
+The ``py`` launcher now forwards its ``STARTUPINFO`` structure to child
+processes.
diff --git a/PC/launcher.c b/PC/launcher.c
index a78620a8924f..a4e678115f34 100644
--- a/PC/launcher.c
+++ b/PC/launcher.c
@@ -666,7 +666,7 @@ run_child(wchar_t * cmdline)
     if (!ok)
         error(RC_CREATE_PROCESS, L"Job information setting failed");
     memset(&si, 0, sizeof(si));
-    si.cb = sizeof(si);
+    GetStartupInfoW(&si);
     ok = safe_duplicate_handle(GetStdHandle(STD_INPUT_HANDLE), &si.hStdInput);
     if (!ok)
         error(RC_NO_STD_HANDLES, L"stdin duplication failed");



More information about the Python-checkins mailing list