mirror of
https://github.com/python/cpython.git
synced 2025-08-03 08:34:29 +00:00
Issue #10780: PyErr_SetFromWindowsErrWithFilename() and
PyErr_SetExcFromWindowsErrWithFilename() decode the filename from the filesystem encoding instead of UTF-8.
This commit is contained in:
parent
83098a4095
commit
92be939695
4 changed files with 11 additions and 6 deletions
|
@ -202,7 +202,7 @@ PyAPI_FUNC(PyObject *) PyErr_SetFromWindowsErrWithFilenameObject(
|
|||
int, const char *);
|
||||
PyAPI_FUNC(PyObject *) PyErr_SetFromWindowsErrWithFilename(
|
||||
int ierr,
|
||||
const char *filename /* decoded from UTF-8 */
|
||||
const char *filename, /* decoded from the filesystem encoding */
|
||||
);
|
||||
#ifndef Py_LIMITED_API
|
||||
/* XXX redeclare to use WSTRING */
|
||||
|
@ -215,7 +215,7 @@ PyAPI_FUNC(PyObject *) PyErr_SetExcFromWindowsErrWithFilenameObject(
|
|||
PyAPI_FUNC(PyObject *) PyErr_SetExcFromWindowsErrWithFilename(
|
||||
PyObject *exc,
|
||||
int ierr,
|
||||
const char *filename /* decoded from UTF-8 */
|
||||
const char *filename, /* decoded from the filesystem encoding */
|
||||
);
|
||||
#ifndef Py_LIMITED_API
|
||||
PyAPI_FUNC(PyObject *) PyErr_SetExcFromWindowsErrWithUnicodeFilename(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue