Skip to content

Commit

Permalink
Fix refleak in ParamSpecArgs/Kwargs
Browse files Browse the repository at this point in the history
  • Loading branch information
JelleZijlstra committed Apr 26, 2023
1 parent 445a39b commit 7fa37b4
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Objects/typevarobject.c
Original file line number Diff line number Diff line change
Expand Up @@ -503,13 +503,15 @@ typedef struct {
static void
paramspecattr_dealloc(PyObject *self)
{
PyTypeObject *tp = Py_TYPE(self);
paramspecattrobject *psa = (paramspecattrobject *)self;

_PyObject_GC_UNTRACK(self);

Py_XDECREF(psa->__origin__);

Py_TYPE(self)->tp_free(self);
Py_DECREF(tp);
}

static int
Expand Down

0 comments on commit 7fa37b4

Please sign in to comment.