X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/2f4e928794167715f19a3021d62b7c4f77611694..84e89e2aac48d44bdb6424cc617c11ed80c370a1:/wxPython/src/helpers.cpp?ds=sidebyside diff --git a/wxPython/src/helpers.cpp b/wxPython/src/helpers.cpp index 28f0621eed..7b29004df3 100644 --- a/wxPython/src/helpers.cpp +++ b/wxPython/src/helpers.cpp @@ -402,8 +402,10 @@ PyObject* wxPyConstructObject(void* ptr, } char buff[64]; // should always be big enough... - sprintf(buff, "%sPtr", className); + + wxASSERT_MSG(wxPython_dict, "wxPython_dict is not set yet!!"); + PyObject* classobj = PyDict_GetItemString(wxPython_dict, buff); if (! classobj) { char temp[128];