Merge pull request #23935 from taosdata/fix/alexduan-3.0
fix: strncpy replace with memcpy on 3.0
This commit is contained in:
commit
0c9e07fdd2
|
@ -732,7 +732,7 @@ int taos_options_imp(TSDB_OPTION option, const char *str) {
|
|||
return -1;
|
||||
}
|
||||
newstr[0] = '"';
|
||||
strncpy(newstr+1, str, len);
|
||||
memcpy(newstr+1, str, len);
|
||||
newstr[len + 1] = '"';
|
||||
newstr[len + 2] = '\0';
|
||||
str = newstr;
|
||||
|
|
Loading…
Reference in New Issue