fix possible null pointer deref - bug 1863647
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@10204 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
e89a5119c3
commit
4c335c9422
1 changed files with 5 additions and 4 deletions
|
|
@ -466,12 +466,13 @@ PySwigObject_dealloc(PyObject *v)
|
|||
res = ((*meth)(mself, v));
|
||||
}
|
||||
Py_XDECREF(res);
|
||||
} else {
|
||||
const char *name = SWIG_TypePrettyName(ty);
|
||||
}
|
||||
#if !defined(SWIG_PYTHON_SILENT_MEMLEAK)
|
||||
printf("swig/python detected a memory leak of type '%s', no destructor found.\n", name);
|
||||
#endif
|
||||
else {
|
||||
const char *name = SWIG_TypePrettyName(ty);
|
||||
printf("swig/python detected a memory leak of type '%s', no destructor found.\n", (name ? name : "unknown"));
|
||||
}
|
||||
#endif
|
||||
}
|
||||
Py_XDECREF(next);
|
||||
PyObject_DEL(v);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue