mirror of
https://github.com/python/cpython.git
synced 2025-08-28 12:45:07 +00:00
gh-94930: skipitem() in getargs.c should return non-NULL on error (GH-94931)
(cherry picked from commit 067f0da335
)
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
This commit is contained in:
parent
a914fa979e
commit
ec6ed6681d
4 changed files with 37 additions and 8 deletions
|
@ -2695,9 +2695,7 @@ skipitem(const char **p_format, va_list *p_va, int flags)
|
|||
if (*format == '#') {
|
||||
if (p_va != NULL) {
|
||||
if (!(flags & FLAG_SIZE_T)) {
|
||||
PyErr_SetString(PyExc_SystemError,
|
||||
"PY_SSIZE_T_CLEAN macro must be defined for '#' formats");
|
||||
return NULL;
|
||||
return "PY_SSIZE_T_CLEAN macro must be defined for '#' formats";
|
||||
}
|
||||
(void) va_arg(*p_va, Py_ssize_t *);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue