未验证 提交 c91fccf2 编写于 作者: sangshuduo's avatar sangshuduo 提交者: GitHub

Hotfix/sangshuduo/td 3633 taosdemo segfault (#5649)

* [TD-3633] <fix>: fix taosdemo segfault.

* [TD-3633] <fix>: fix taosdemo segfault.

use snprintf instead of sprintf.
Co-authored-by: NShuduo Sang <sdsang@taosdata.com>
上级 bf2ac148
......@@ -4455,7 +4455,7 @@ static int generateDataTail(char *tableName, int32_t tableSeq,
break;
}
buffer += sprintf(buffer, " %s", data);
buffer += snprintf(buffer, retLen + 1, "%s", data);
k++;
len += retLen;
remainderBufLen -= retLen;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册