Skip to content

Commit

Permalink
Fix keys iterator memory leak (#453)
Browse files Browse the repository at this point in the history
  • Loading branch information
Reskov authored and asvetlov committed Jan 11, 2020
1 parent dda85cf commit edb0e9f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGES/452.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
``MultiDict.iter`` fix memory leak when used iterator over `multidict` instance.
2 changes: 1 addition & 1 deletion multidict/_multidict.c
Original file line number Diff line number Diff line change
Expand Up @@ -572,7 +572,7 @@ multidict_sq_contains(MultiDictObject *self, PyObject *key)
static inline PyObject *
multidict_tp_iter(MultiDictObject *self)
{
return PyObject_GetIter(multidict_keysview_new((PyObject*)self));
return multidict_keys_iter_new(self);
}

static inline PyObject *
Expand Down

0 comments on commit edb0e9f

Please sign in to comment.