fix PyUnicodeDecodeError_Create
This commit is contained in:
parent
af2ad45c73
commit
faa578a7c5
|
@ -85,18 +85,17 @@ pub unsafe fn PyUnicodeDecodeError_Create(
|
|||
length: Py_ssize_t,
|
||||
start: Py_ssize_t,
|
||||
end: Py_ssize_t,
|
||||
_reason: *const c_char,
|
||||
reason: *const c_char,
|
||||
) -> *mut PyObject {
|
||||
crate::PyObject_CallFunction(
|
||||
PyExc_UnicodeDecodeError,
|
||||
std::ffi::CStr::from_bytes_with_nul(b"sy#nns\0")
|
||||
.unwrap()
|
||||
.as_ptr(),
|
||||
b"sy#nns\0".as_ptr().cast::<c_char>(),
|
||||
encoding,
|
||||
object,
|
||||
length,
|
||||
start,
|
||||
end,
|
||||
reason,
|
||||
)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue