Use memcpy() instead of strlcpy() in two places where the source length is

known and the destination length is known to be sufficient.


git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@376 13b04d17-f746-0410-82c6-800466cd88b0
This commit is contained in:
Kevin Easton
2013-09-28 14:01:23 +00:00
parent 07c6a61fed
commit d7bdc25960

View File

@@ -453,7 +453,7 @@ Tcl_GetKeyedListKeys (tcl_interp, subFieldName, keyedList, keysArgcPtr,
NULL);
TclFindElement (tcl_interp, fieldPtr, &keyPtr, &dummyPtr, &keySize, NULL);
keyArgv [idx++] = nextByte;
strlcpy (nextByte, keyPtr, keySize);
memcpy (nextByte, keyPtr, keySize);
nextByte [keySize] = '\0';
nextByte += keySize + 1;
}
@@ -578,7 +578,7 @@ int Tcl_GetKeyedListField (tcl_interp, fieldName, keyedList, fieldValuePtr)
fieldValue = ckalloc (valueSize + 1);
if (braced)
{
strlcpy (fieldValue, valuePtr, valueSize);
memcpy (fieldValue, valuePtr, valueSize);
fieldValue [valueSize] = 0;
}
else