We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
PyErr_NoMemory()
type_from_slots_or_spec
1 parent 7b765a4 commit 2ff445bCopy full SHA for 2ff445b
2 files changed
Misc/ACKS
@@ -2144,6 +2144,7 @@ Xiang Zhang
2144
Robert Xiao
2145
Florent Xicluna
2146
Yanbo, Xie
2147
+Ivy Xu
2148
Kaisheng Xu
2149
Xinhang Xu
2150
Arnon Yaari
Objects/typeobject.c
@@ -5488,6 +5488,7 @@ type_from_slots_or_spec(
5488
Py_ssize_t name_buf_len = strlen(it.name) + 1;
5489
_ht_tpname = PyMem_Malloc(name_buf_len);
5490
if (_ht_tpname == NULL) {
5491
+ PyErr_NoMemory();
5492
goto finally;
5493
}
5494
memcpy(_ht_tpname, it.name, name_buf_len);
@@ -5774,7 +5775,7 @@ type_from_slots_or_spec(
5774
5775
((PyObject*)type)->ob_flags |= _Py_TYPE_REVEALED_FLAG;
5776
#endif
5777
- finally:
5778
+finally:
5779
if (PyErr_Occurred()) {
5780
Py_CLEAR(res);
5781
0 commit comments