python: Fix exception leak.
authorJustus Winter <justus@g10code.com>
Mon, 13 Jun 2016 16:35:47 +0000 (18:35 +0200)
committerJustus Winter <justus@g10code.com>
Thu, 16 Jun 2016 12:07:41 +0000 (14:07 +0200)
* lang/python/helpers.c (pygpgme_stash_callback_exception): Fix leak.

Signed-off-by: Justus Winter <justus@g10code.com>
lang/python/helpers.c

index 0033ef0..810423d 100644 (file)
@@ -122,6 +122,7 @@ static void pygpgme_stash_callback_exception(PyObject *weak_self)
     }
   else
     PyObject_SetAttrString(self, EXCINFO, excinfo);
+  Py_DECREF(excinfo);
 }
 
 PyObject *pygpgme_raise_callback_exception(PyObject *self)