@@ -124,7 +124,7 void ShellImplGenerator::write(QTextStream &s, const AbstractMetaClass *meta_cla | |||
|
124 | 124 | Option typeOptions = Option(OriginalName | UnderscoreSpaces | SkipName); |
|
125 | 125 | AbstractMetaArgumentList args = fun->arguments(); |
|
126 | 126 | |
|
127 | s << "if (_wrapper) {" << endl; | |
|
127 | s << "if (_wrapper && (_wrapper->ob_refcnt > 0)) {" << endl; | |
|
128 | 128 | s << " static PyObject* name = PyString_FromString(\"" << fun->name() << "\");" << endl; |
|
129 | 129 | s << " PyObject* obj = PyBaseObject_Type.tp_getattro((PyObject*)_wrapper, name);" << endl; |
|
130 | 130 | s << " if (obj) {" << endl; |
General Comments 0
You need to be logged in to leave comments.
Login now