diff options
author | zeertzjq <zeertzjq@outlook.com> | 2022-05-03 09:29:55 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-03 09:29:55 +0800 |
commit | 13520aae163bfc243fc050cf16b89082c0896eaf (patch) | |
tree | 7487c15a5539ba28ebeb10035587f4b870bbc70f /src/nvim/api/ui.c | |
parent | cf474021ed44f197da3c67214fcb95a20886799c (diff) | |
download | rneovim-13520aae163bfc243fc050cf16b89082c0896eaf.tar.gz rneovim-13520aae163bfc243fc050cf16b89082c0896eaf.tar.bz2 rneovim-13520aae163bfc243fc050cf16b89082c0896eaf.zip |
fix(coverity): use xstrndup() instead of vim_strsave() (#18363)
Diffstat (limited to 'src/nvim/api/ui.c')
-rw-r--r-- | src/nvim/api/ui.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nvim/api/ui.c b/src/nvim/api/ui.c index f449ccc3c7..d1b86ed328 100644 --- a/src/nvim/api/ui.c +++ b/src/nvim/api/ui.c @@ -261,7 +261,7 @@ static void ui_set_option(UI *ui, bool init, String name, Object value, Error *e api_set_error(error, kErrorTypeValidation, "term_name must be a String"); return; } - set_tty_option("term", xstrdup(value.data.string.data)); + set_tty_option("term", string_to_cstr(value.data.string)); return; } |