fix #1188207 and uniform the error/null/none handling
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@7225 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
645c1698fa
commit
a2f5af9ddd
5 changed files with 11 additions and 17 deletions
|
|
@ -132,8 +132,8 @@ SWIGINTERNINLINE PyObject *
|
|||
SWIG_FromWCharArray(const wchar_t * carray, size_t size)
|
||||
{
|
||||
if (size > INT_MAX) {
|
||||
SWIG_NewPointerObj(SWIG_const_cast(carray,wchar_t *), SWIG_TypeQuery("wchar_t *"), 0);
|
||||
return Py_None;
|
||||
return SWIG_NewPointerObj(SWIG_const_cast(carray,wchar_t *),
|
||||
SWIG_TypeQuery("wchar_t *"), 0);
|
||||
} else {
|
||||
return PyUnicode_FromWideChar(carray, SWIG_numeric_cast(size,int));
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue