Use memcpy instead of strcpy to improve performance.

This commit is contained in:
Dan Fandrich 2007-05-01 20:50:50 +00:00
parent 60588b2455
commit 93844f64ef

View File

@ -38,7 +38,7 @@ char *curlx_strdup(const char *str)
if (!newstr)
return (char *)NULL;
strcpy(newstr,str);
memcpy(newstr,str,(len+1)*sizeof(char));
return newstr;