..
-.. date: 2024-04-13-18-59-25
-.. gh-issue: 115874
-.. nonce: c3xG-E
-.. section: Core and Builtins
-
-Fixed a possible segfault during garbage collection of
-``_asyncio.FutureIter`` objects
-
-..
-
.. date: 2024-04-13-16-55-53
.. gh-issue: 117536
.. nonce: xkVbfv
..
+.. date: 2024-04-13-18-59-25
+.. gh-issue: 115874
+.. nonce: c3xG-E
+.. section: Library
+
+Fixed a possible segfault during garbage collection of
+``_asyncio.FutureIter`` objects. Patch by Savannah Ostrowski.
+
+..
+
.. date: 2024-04-13-01-45-15
.. gh-issue: 115060
.. nonce: IxoM03
{
PyTypeObject *tp = Py_TYPE(it);
- // FutureIter is a heap type so any subclass must also be a heap type.
assert(_PyType_HasFeature(tp, Py_TPFLAGS_HEAPTYPE));
PyObject *module = ((PyHeapTypeObject*)tp)->ht_module;
// GH-115874: We can't use PyType_GetModuleByDef here as the type might have
// already been cleared, which is also why we must check if ht_module != NULL.
- // Due to this restriction, subclasses that belong to a different module
- // will not be able to use the free list.
if (module && _PyModule_GetDef(module) == &_asynciomodule) {
state = get_asyncio_state(module);
}