Fixed Python string handling bug
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@907 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
319317814a
commit
44f72308da
1 changed files with 1 additions and 1 deletions
|
|
@ -569,7 +569,7 @@ PYTHON::create_function(char *name, char *iname, SwigType *d, ParmList *l) {
|
|||
SwigType_del_pointer(d);
|
||||
break;
|
||||
case T_STRING:
|
||||
Printf(f->code," resultobj = PyString_FromString(result);\n");
|
||||
Printf(f->code," resultobj = Py_BuildValue(\"s\",result);\n");
|
||||
break;
|
||||
case T_POINTER: case T_ARRAY: case T_REFERENCE:
|
||||
SwigType_remember(d);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue