fix DECREF of borrowed reference
authorStefan Behnel <scoder@users.berlios.de>
Mon, 29 Oct 2007 18:35:57 +0000 (19:35 +0100)
committerStefan Behnel <scoder@users.berlios.de>
Mon, 29 Oct 2007 18:35:57 +0000 (19:35 +0100)
Cython/Compiler/ModuleNode.py

index 7fd8ce83badaebc4cfc5b27b62cc60357dbb90cb..6d28e665418bfc2447157571e75e6957a5c434f8 100644 (file)
@@ -1716,11 +1716,9 @@ static int __Pyx_ImportFunction(PyObject *module, char *funcname, void **f, char
         goto bad;
     }
     *f = PyCObject_AsVoidPtr(cobj);
-    Py_DECREF(cobj);
     Py_DECREF(d);
     return 0;
 bad:
-    Py_XDECREF(cobj);
     Py_XDECREF(d);
     return -1;
 }