| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
…param_bound_or_default` (pythonGH-152684) In `symtable_visit_type_param_bound_or_default()`, when a reserved name (e.g. `__classdict__`) is used as a type parameter, `PyUnicode_FromFormat()` is called to build the SyntaxError message. If the allocation fails and returns NULL, the subsequent `PyErr_SetObject()` and `Py_DECREF()` calls would dereference NULL, causing a segfault. Fix by returning 0 immediately when `PyUnicode_FromFormat()` returns NULL. This propagates the MemoryError set by `PyUnicode_FromFormat()`. The bug was introduced in pythongh-128632 (commit 891c61c). (cherry picked from commit 10ed03e) Co-authored-by: Petr Vaganov <petrvaganoff@gmail.com>
|
Disabling till #152684 (comment) is decided. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
In symtable_visit_type_param_bound_or_default(), when a reserved name
(e.g. __classdict__) is used as a type parameter, PyUnicode_FromFormat()
is called to build the SyntaxError message. If the allocation fails and
returns NULL, the subsequent PyErr_SetObject() and Py_DECREF() calls
would dereference NULL, causing a segfault.
Fix by returning 0 immediately when PyUnicode_FromFormat() returns NULL.
This propagates the MemoryError set by PyUnicode_FromFormat().
The bug was introduced in gh-128632 (commit 891c61c).
(cherry picked from commit 10ed03e)
Co-authored-by: Petr Vaganov petrvaganoff@gmail.com