mirror of
https://github.com/python/cpython.git
synced 2025-10-07 07:31:46 +00:00
Py_BuildValue's 'c' code should use byte strings #5666
This commit is contained in:
parent
a3b1ac8dca
commit
a921fb0f66
4 changed files with 11 additions and 7 deletions
|
@ -1141,14 +1141,14 @@ array_reduce(arrayobject *array)
|
|||
> PY_SSIZE_T_MAX / Py_SIZE(array)) {
|
||||
return PyErr_NoMemory();
|
||||
}
|
||||
result = Py_BuildValue("O(cy#)O",
|
||||
result = Py_BuildValue("O(Cy#)O",
|
||||
Py_TYPE(array),
|
||||
array->ob_descr->typecode,
|
||||
array->ob_item,
|
||||
Py_SIZE(array) * array->ob_descr->itemsize,
|
||||
dict);
|
||||
} else {
|
||||
result = Py_BuildValue("O(c)O",
|
||||
result = Py_BuildValue("O(C)O",
|
||||
Py_TYPE(array),
|
||||
array->ob_descr->typecode,
|
||||
dict);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue