Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 1304f2d

Browse files
author
Victor Stinner
committed
Issue #3080: Fix case_ok() using case_bytes()
Invert name and namelen arguments.
1 parent 22a8cbe commit 1304f2d

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

Python/import.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2208,8 +2208,8 @@ case_ok(PyObject *filename, Py_ssize_t prefix_delta, PyObject *name)
22082208
match = case_bytes(
22092209
PyBytes_AS_STRING(filebytes),
22102210
PyBytes_GET_SIZE(filebytes) + prefix_delta,
2211-
PyBytes_AS_STRING(namebytes),
2212-
PyBytes_GET_SIZE(namebytes));
2211+
PyBytes_GET_SIZE(namebytes),
2212+
PyBytes_AS_STRING(namebytes));
22132213
Py_DECREF(filebytes);
22142214
Py_DECREF(namebytes);
22152215
return match;

0 commit comments

Comments
 (0)