In -scm mode, don't forget to check the type of string arguments.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@5742 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
3e2c500127
commit
4976eb0725
1 changed files with 2 additions and 0 deletions
|
|
@ -77,6 +77,8 @@ SWIG_Guile_scm2newstr(SCM str, size_t *len) {
|
|||
char *ret;
|
||||
size_t l;
|
||||
|
||||
SCM_ASSERT (SCM_STRINGP(str), str, 1, FUNC_NAME);
|
||||
|
||||
l = SCM_STRING_LENGTH(str);
|
||||
ret = (char *) SWIG_malloc( (l + 1) * sizeof(char));
|
||||
if (!ret) return NULL;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue