[issue36150] Possible assertion failures due to _ctypes.c's PyCData_reduce()

Zackery Spytz report at bugs.python.org
Fri Mar 29 03:45:49 EDT 2019


Zackery Spytz <zspytz at gmail.com> added the comment:

I again encountered an assertion failure that involved PyCData_reduce(). In that function, PyBytes_FromStringAndSize() may be evaluated before PyObject_GetAttrString(). If a MemoryError occurs in PyBytes_FromStringAndSize(), an assertion failure will occur in _PyType_Lookup() when PyObject_GetAttrString() is called.

The assertion failure occurs before the Py_BuildValue() call. Please reopen the issue and the PR.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue36150>
_______________________________________


More information about the Python-bugs-list mailing list