bugfix: string conversion routine was returning size+1

this was true when only VT_STR existed
This commit is contained in:
elias.bachaalany 2010-02-12 12:56:14 +00:00
parent bbabb3d6fa
commit e056f5670f

View File

@ -334,7 +334,7 @@ int pyvar_to_idcvar(
return 1;
// String
else if (PyString_Check(py_var))
idc_var->_set_string(PyString_AsString(py_var), PyString_Size(py_var)+1);
idc_var->_set_string(PyString_AsString(py_var), PyString_Size(py_var));
// Float
else if (PyBool_Check(py_var))
idc_var->set_long(py_var == Py_True ? 1 : 0);