10000 bpo-43321: Fix SystemError in getargs.c by methane · Pull Request #24656 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

bpo-43321: Fix SystemError in getargs.c #24656

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Feb 27, 2021
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
reorder macros
  • Loading branch information
methane committed Feb 27, 2021
commit ff7e10464a42d1b20ea7b77571ca3d491b388c1e
2 changes: 1 addition & 1 deletion Python/getargs.c
Original file line number Diff line number Diff line change
Expand Up @@ -655,14 +655,14 @@ static const char *
convertsimple(PyObject *arg, const char **p_format, va_list *p_va, int flags,
char *msgbuf, size_t bufsize, freelist_t *freelist)
{
#define RETURN_ERR_OCCURRED return msgbuf
/* For # codes */
#define REQUIRE_PY_SSIZE_T_CLEAN \
if (!(flags & FLAG_SIZE_T)) { \
PyErr_SetString(PyExc_SystemError, \
"PY_SSIZE_T_CLEAN macro must be defined for '#' formats"); \
RETURN_ERR_OCCURRED; \
}
#define RETURN_ERR_OCCURRED return msgbuf

const char *format = *p_format;
char c = *format++;
Expand Down
0