Skip to content

Commit d82788e

Browse files
committed
decref EVPtype in EVP_dealloc
Signed-off-by: Christian Heimes <[email protected]>
1 parent a172388 commit d82788e

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

Modules/_hashopenssl.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -283,10 +283,12 @@ EVP_hash(EVPobject *self, const void *vp, Py_ssize_t len)
283283
static void
284284
EVP_dealloc(EVPobject *self)
285285
{
286+
PyTypeObject *tp = Py_TYPE(self);
286287
if (self->lock != NULL)
287288
PyThread_free_lock(self->lock);
288289
EVP_MD_CTX_free(self->ctx);
289290
PyObject_Del(self);
291+
Py_DECREF(tp);
290292
}
291293

292294
static int

0 commit comments

Comments
 (0)