mirror of
https://github.com/python/cpython.git
synced 2025-07-24 11:44:31 +00:00
Issue #27048: Prevents distutils failing on Windows when environment variables contain non-ASCII characters
This commit is contained in:
parent
85e6635edf
commit
08bb8a41cc
3 changed files with 23 additions and 4 deletions
|
@ -86,11 +86,9 @@ def _get_vc_env(plat_spec):
|
|||
|
||||
try:
|
||||
out = subprocess.check_output(
|
||||
'"{}" {} && set'.format(vcvarsall, plat_spec),
|
||||
shell=True,
|
||||
'cmd /u /c "{}" {} && set'.format(vcvarsall, plat_spec),
|
||||
stderr=subprocess.STDOUT,
|
||||
universal_newlines=True,
|
||||
)
|
||||
).decode('utf-16le', errors='replace')
|
||||
except subprocess.CalledProcessError as exc:
|
||||
log.error(exc.output)
|
||||
raise DistutilsPlatformError("Error executing {}"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue