#3965: on Windows, open() crashes if the filename or the mode is invalid,
and if the filename is a unicode string.

Reviewed by Martin von Loewis.
3 files changed