Issue #850997: mbcs encoding (Windows only) handles errors argument: strict

mode raises unicode errors. The encoder only supports "strict" and "replace"
error handlers, the decoder only supports "strict" and "ignore" error handlers.
This commit is contained in:
Victor Stinner 2010-06-16 23:33:54 +00:00
parent 79ee19f3db
commit 554f3f0081
5 changed files with 149 additions and 45 deletions

View file

@ -265,7 +265,7 @@ except ImportError:
pass
else:
if _os.name in ("nt", "ce"):
set_conversion_mode("mbcs", "ignore")
set_conversion_mode("mbcs", "strict")
else:
set_conversion_mode("ascii", "strict")