fix null char* case, reported by Daniel Moore

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@9078 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
Marcelo Matus 2006-05-03 22:46:25 +00:00
commit 20e425f31b

View file

@ -506,7 +506,7 @@
SWIGINTERNINLINE SWIG_Object
SWIG_From##CharName##Ptr(const Char *cptr)
{
return SWIG_FromCharPtrAndSize(cptr, (cptr ? SWIG_CharPtrLen(cptr) + 1: 0));
return SWIG_FromCharPtrAndSize(cptr, (cptr ? SWIG_CharPtrLen(cptr) : 0));
}
}