Issue #16826: Don't check for PYTHONCASEOK when using -E.

This commit fixes a regression that sneaked into Python 3.3 where importlib
was not respecting -E when checking for the PYTHONCASEOK environment variable.
This commit is contained in:
Meador Inge 2013-09-03 16:37:26 -05:00
parent 9edb168dd7
commit d151da9ef7
5 changed files with 4322 additions and 4244 deletions

View file

@ -33,7 +33,10 @@ def _make_relax_case():
if sys.platform.startswith(_CASE_INSENSITIVE_PLATFORMS):
def _relax_case():
"""True if filenames must be checked case-insensitively."""
return b'PYTHONCASEOK' in _os.environ
if sys.flags.ignore_environment:
return False
else:
return b'PYTHONCASEOK' in _os.environ
else:
def _relax_case():
"""True if filenames must be checked case-insensitively."""