Incorrect increment of reference count on persistent type object.

This commit is contained in:
Graham Dumpleton
2013-09-19 22:19:28 +10:00
parent e3d8dc8559
commit 7c573fe306

View File

@@ -2054,13 +2054,10 @@ static int WraptFunctionWrapper_init(WraptFunctionWrapperObject *self,
if (PyObject_IsInstance(wrapped,
(PyObject *)&PyClassMethod_Type) || PyObject_IsInstance(
wrapped, (PyObject *)&PyStaticMethod_Type)) {
Py_INCREF((PyObject *)&WraptBoundFunctionWrapper_Type);
bound_type = (PyObject *)&WraptBoundFunctionWrapper_Type;
}
else {
Py_INCREF((PyObject *)&WraptBoundMethodWrapper_Type);
else
bound_type = (PyObject *)&WraptBoundMethodWrapper_Type;
}
result = WraptFunctionWrapperBase_raw_init(self, wrapped, Py_None,
wrapper, adapter, bound_type);