Author: Alex Gaynor <alex.gay...@gmail.com> Branch: Changeset: r82242:f5bb0b58e857 Date: 2016-02-14 11:22 -0500 http://bitbucket.org/pypy/pypy/changeset/f5bb0b58e857/
Log: Merged in HawkOwl/pypy (pull request #400) Check for the existence of CODESET, not that it's a truthy value. diff --git a/pypy/module/sys/interp_encoding.py b/pypy/module/sys/interp_encoding.py --- a/pypy/module/sys/interp_encoding.py +++ b/pypy/module/sys/interp_encoding.py @@ -42,7 +42,7 @@ def _getfilesystemencoding(space): encoding = base_encoding - if rlocale.HAVE_LANGINFO and rlocale.CODESET: + if rlocale.HAVE_LANGINFO and hasattr(rlocale, "CODESET"): try: oldlocale = rlocale.setlocale(rlocale.LC_CTYPE, None) rlocale.setlocale(rlocale.LC_CTYPE, "") _______________________________________________ pypy-commit mailing list pypy-commit@python.org https://mail.python.org/mailman/listinfo/pypy-commit