summaryrefslogtreecommitdiff
path: root/python/generic.cc
diff options
context:
space:
mode:
Diffstat (limited to 'python/generic.cc')
-rw-r--r--python/generic.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/python/generic.cc b/python/generic.cc
index d3f6a6d6..84dda9aa 100644
--- a/python/generic.cc
+++ b/python/generic.cc
@@ -107,6 +107,9 @@ PyObject *_PyAptObject_getattro(PyObject *self, PyObject *attr) {
PyErr_Restore(ptype, pvalue, ptraceback);
}
Py_DECREF(newattr);
+ Py_XDECREF(ptype);
+ Py_XDECREF(pvalue);
+ Py_XDECREF(ptraceback);
}
return value;
}