diff --git a/numpy/core/src/multiarray/scalartypes.c.src b/numpy/core/src/multiarray/scalartypes.c.src index 47553ff8a9dd..2976e065bb78 100644 --- a/numpy/core/src/multiarray/scalartypes.c.src +++ b/numpy/core/src/multiarray/scalartypes.c.src @@ -319,7 +319,7 @@ genint_type_str(PyObject *self) item = gentype_generic_method(self, NULL, NULL, "item"); break; } - Py_DECREF(descr); + Py_DECREF(dtype); if (item == NULL) { return NULL; }