mirror of
https://github.com/python/cpython.git
synced 2025-11-01 18:51:43 +00:00
bpo-39943: Add the const qualifier to pointers on non-mutable PyUnicode data. (GH-19345)
This commit is contained in:
parent
7ec43a7309
commit
cd8295ff75
27 changed files with 250 additions and 221 deletions
|
|
@ -228,7 +228,7 @@ multibytecodec_encerror(MultibyteCodec *codec,
|
|||
Py_ssize_t r;
|
||||
Py_ssize_t inpos;
|
||||
int kind;
|
||||
void *data;
|
||||
const void *data;
|
||||
|
||||
replchar = PyUnicode_FromOrdinal('?');
|
||||
if (replchar == NULL)
|
||||
|
|
@ -457,7 +457,7 @@ multibytecodec_encode(MultibyteCodec *codec,
|
|||
Py_ssize_t finalsize, r = 0;
|
||||
Py_ssize_t datalen;
|
||||
int kind;
|
||||
void *data;
|
||||
const void *data;
|
||||
|
||||
if (PyUnicode_READY(text) < 0)
|
||||
return NULL;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue