Discussion:
[omniORB] memory leak in idlpython.cc
Wei Jiang
2009-10-20 12:44:41 UTC
Permalink
Index: src/tool/omniidl/cxx/idlpython.cc
===================================================================
--- src/tool/omniidl/cxx/idlpython.cc (?? 5926)
+++ src/tool/omniidl/cxx/idlpython.cc (????)
@@ -675,8 +675,9 @@
// Give each Declarator a reference to the Typedef. This creates a
// loop which Python's GC won't collect :-(
for (i=0; i<l; ++i) {
- PyObject_CallMethod(PyList_GetItem(pydeclarators, i),
+ PyObject* r = PyObject_CallMethod(PyList_GetItem(pydeclarators, i),
(char*)"_setAlias", (char*)"O", result_);
+ ASSERT_PYOBJ(r); Py_DECREF(r);
}
}

Loading...