未验证 提交 74bc6dbc 编写于 作者: O oceanbase-admin 提交者: GitHub

Merge pull request #7 from shenchai/feature_fix_memset

fix memset to '0' for zerofill
...@@ -107,7 +107,7 @@ static int copy_string(const ObObjCastParams &params, ...@@ -107,7 +107,7 @@ static int copy_string(const ObObjCastParams &params,
} else { } else {
int64_t zf = params.zf_info_->max_length_ - len; int64_t zf = params.zf_info_->max_length_ - len;
if (zf > 0) { if (zf > 0) {
MEMSET(buf, 0, zf); MEMSET(buf, '0', zf);
MEMCPY(buf + zf, str, len); MEMCPY(buf + zf, str, len);
len = str_len; // set string length len = str_len; // set string length
} else { } else {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册