]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/src/mac/xrc_wrap.cpp
'[1219035] cleanup: miscellaneous' and minor source cleaning.
[wxWidgets.git] / wxPython / src / mac / xrc_wrap.cpp
index ef8ca47db08f9ef2e46b9ec452a0304758911151..c5e5990b95c57cb04e8c76414b1415a4e1ef91ce 100644 (file)
@@ -1037,7 +1037,8 @@ SWIG_Python_TypeError(const char *type, PyObject *obj)
          PyErr_Format(PyExc_TypeError, "a '%s' is expected, '%s' is received",
                       type, otype);
        }
-       Py_DECREF(str);
+       if (str)
+          Py_DECREF(str);
        return;
       }
     }