Skip to content

Commit

Permalink
test with memcpy
Browse files Browse the repository at this point in the history
Checking if memcpy use less than strlcpy
  • Loading branch information
bilaliscarioth authored Jan 16, 2025
1 parent 675ef46 commit a4fdb6c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cores/arduino/WString.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ unsigned char String::concat(const char *cstr, unsigned int length)
if (!cstr) return 0;
if (length == 0) return 1;
if (!reserve(newlen)) return 0;
strlcpy(buffer + len, cstr, length);
memcpy(buffer + len, cstr, length);
len = newlen;
return 1;
}
Expand Down

0 comments on commit a4fdb6c

Please sign in to comment.