mirror of
https://github.com/arendst/Tasmota.git
synced 2025-07-29 05:36:39 +00:00
parent
c6507482c4
commit
b8e7ee8650
@ -143,7 +143,7 @@ char* subStr(char* dest, char* str, const char *delim, int index)
|
|||||||
int i;
|
int i;
|
||||||
|
|
||||||
// Since strtok consumes the first arg, make a copy
|
// Since strtok consumes the first arg, make a copy
|
||||||
strlcpy(dest, str, strlen(str));
|
strncpy(dest, str, strlen(str));
|
||||||
for (i = 1, act = dest; i <= index; i++, act = NULL) {
|
for (i = 1, act = dest; i <= index; i++, act = NULL) {
|
||||||
sub = strtok_r(act, delim, &ptr);
|
sub = strtok_r(act, delim, &ptr);
|
||||||
if (sub == NULL) break;
|
if (sub == NULL) break;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user