10000 decref the type · python/cpython@00a468c · GitHub
[go: up one dir, main page]

Skip to content

Commit 00a468c

Browse files
committed
decref the type
1 parent 88d58ff commit 00a468c

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

Modules/_blake2/blake2b_impl.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -391,6 +391,9 @@ py_blake2b_dealloc(PyObject *self)
391391
PyThread_free_lock(obj->lock);
392392
obj->lock = NULL;
393393
}
394+
PyTypeObject *tp = Py_TYPE(self);
395+
Py_DECREF(tp);
396+
394397
PyObject_Del(self);
395398
}
396399

Modules/_blake2/blake2s_impl.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -390,6 +390,10 @@ py_blake2s_dealloc(PyObject *self)
390390
PyThread_free_lock(obj->lock);
391391
obj->lock = NULL;
392392
}
393+
394+
PyTypeObject *tp = Py_TYPE(self);
395+
Py_DECREF(tp);
396+
393397
PyObject_Del(self);
394398
}
395399

0 commit comments

Comments
 (0)
0