fix: lastWordBytes need add 1

This commit is contained in:
Alex Duan 2024-10-28 16:27:52 +08:00
parent 6b6c9c884e
commit 462dc3362f
1 changed files with 1 additions and 0 deletions

View File

@ -1335,6 +1335,7 @@ void printScreen(TAOS* con, SShellCmd* cmd, SWords* match) {
if (p) { if (p) {
tstrncpy(p, str, strLen + 1); tstrncpy(p, str, strLen + 1);
tstrncpy(p + strLen, ";", 1 + 1); tstrncpy(p + strLen, ";", 1 + 1);
lastWordBytes += 1;
shellInsertStr(cmd, (char*)p, strLen + 1); shellInsertStr(cmd, (char*)p, strLen + 1);
taosMemoryFree(p); taosMemoryFree(p);
} else { } else {