Use memcpy instead of strncpy in s48_enter_substring.

S48 1.0.1 does this and it's faster
.
This commit is contained in:
mainzelm 2002-08-16 12:29:27 +00:00
parent 4540ad4589
commit ffc4491251
1 changed files with 1 additions and 1 deletions

View File

@ -1114,7 +1114,7 @@ s48_value
s48_enter_substring(char *str, int length)
{
s48_value obj = s48_allocate_stob(S48_STOBTYPE_STRING, length + 1);
strncpy(S48_UNSAFE_EXTRACT_STRING(obj), str, length);
memcpy(S48_UNSAFE_EXTRACT_STRING(obj), str, length);
*(S48_UNSAFE_EXTRACT_STRING(obj) + length) = '\0';
return obj;
}