mirror of
https://gitee.com/zlgopen/awtk.git
synced 2024-12-02 20:18:22 +08:00
fix str_set_with_len
This commit is contained in:
parent
227b36914c
commit
517e6b0fd6
@ -79,6 +79,7 @@ ret_t str_set_with_len(str_t* str, const char* text, uint32_t len) {
|
||||
|
||||
tk_strncpy(str->str, text, size);
|
||||
str->size = size;
|
||||
str->str[str->size] = '\0';
|
||||
|
||||
return RET_OK;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user