diff options
author | Steve Dower <steve.dower@python.org> | 2019-06-29 10:34:11 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-06-29 10:34:11 -0700 |
commit | 9048c49322a5229ff99610aba35913ffa295ebb7 (patch) | |
tree | caad6f4a3b44e547208ac70cc1746c4df349ac8f /Lib/multiprocessing | |
parent | 80097e089ba22a42d804e65fbbcf35e5e49eed00 (diff) | |
download | cpython-git-9048c49322a5229ff99610aba35913ffa295ebb7.tar.gz |
bpo-37369: Fix initialization of sys members when launched via an app container (GH-14428)
sys._base_executable is now always defined on all platforms, and can be overridden through configuration.
Also adds test.support.PythonSymlink to encapsulate platform-specific logic for symlinking sys.executable
Diffstat (limited to 'Lib/multiprocessing')
-rw-r--r-- | Lib/multiprocessing/popen_spawn_win32.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/Lib/multiprocessing/popen_spawn_win32.py b/Lib/multiprocessing/popen_spawn_win32.py index de4c5ecf1f..ea9c555da3 100644 --- a/Lib/multiprocessing/popen_spawn_win32.py +++ b/Lib/multiprocessing/popen_spawn_win32.py @@ -22,8 +22,7 @@ WINSERVICE = sys.executable.lower().endswith("pythonservice.exe") def _path_eq(p1, p2): return p1 == p2 or os.path.normcase(p1) == os.path.normcase(p2) -WINENV = (hasattr(sys, '_base_executable') and - not _path_eq(sys.executable, sys._base_executable)) +WINENV = not _path_eq(sys.executable, sys._base_executable) def _close_handles(*handles): |