From: Robin Dunn Date: Sun, 22 Oct 2006 04:13:04 +0000 (+0000) Subject: the Append also does an INCREF, that's one more than we need. X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/cd0a59fb7f471eae4ca931c791df4da5cdceadfd the Append also does an INCREF, that's one more than we need. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@42227 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/wxPython/src/helpers.cpp b/wxPython/src/helpers.cpp index 7bfbb60175..8da21b5270 100644 --- a/wxPython/src/helpers.cpp +++ b/wxPython/src/helpers.cpp @@ -1822,6 +1822,7 @@ PyObject* wxPy_ConvertList(wxListBase* listbase) { wxObj = node->GetData(); pyObj = wxPyMake_wxObject(wxObj,false); PyList_Append(pyList, pyObj); + Py_DECREF(pyObj); // the Append also does an INCREF, that's one more than we need. node = node->GetNext(); } wxPyEndBlockThreads(blocked);