From 3026a5f41db83ff3af83dd9064461c4c15eaed64 Mon Sep 17 00:00:00 2001 From: Jan Edmund Lazo Date: Sun, 13 Dec 2020 12:04:16 -0500 Subject: vim-patch:8.2.2136: Vim9: Using uninitialized variable Problem: Vim9: Using uninitialized variable. Solution: Initialize "len" to zero. Clean up fnamemodify(). https://github.com/vim/vim/commit/c530852315517a44354edbbd6c3375355bbec37e N/A patches for version.c: vim-patch:8.1.0839: when using VTP wrong colors after a color scheme change Problem: When using VTP wrong colors after a color scheme change. Solution: When VTP is active always clear after a color scheme change. (Nobuhiro Takasaki, closes vim/vim#3872) https://github.com/vim/vim/commit/f58d81a18752cb9bf899b3f7328fc489cf6558e8 vim-patch:8.1.2382: MS-Windows: When using VTP bold+inverse doesn't work Problem: MS-Windows: When using VTP bold+inverse doesn't work. Solution: Compare with the default colors. (Nobuhiro Takasaki, closes vim/vim#5303) https://github.com/vim/vim/commit/a050b9471c66b383ed674bfd57ac78016199d972 vim-patch:8.2.0669: MS-Windows: display in VTP is a bit slow Problem: MS-Windows: display in VTP is a bit slow. Solution: Optimize the code. (Nobuhiro Takasaki, closes vim/vim#6014) https://github.com/vim/vim/commit/4e5534fab798ab7c95554da3bc80b08336aedc2b vim-patch:8.2.0739: incomplete profiling when exiting because of a dealy signal Problem: Incomplete profiling when exiting because of a dealy signal. Solution: Call __gcov_flush() if available. https://github.com/vim/vim/commit/b415168a9862023462b7193e83da948cb8d11893 vim-patch:8.2.1911: tiny build fails Problem: Tiny build fails. Solution: Add #ifdef. https://github.com/vim/vim/commit/977fd0b327ed46a71c80d2cd62cbe149d43b9a69 vim-patch:8.2.2140: build failure with tiny features Problem: Build failure with tiny features. Solution: Add #ifdef. https://github.com/vim/vim/commit/2a3cd3af455973d678f70303ebdd486f3478bc0d --- src/nvim/eval/funcs.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/nvim/eval/funcs.c b/src/nvim/eval/funcs.c index b56034b92d..89d9a85775 100644 --- a/src/nvim/eval/funcs.c +++ b/src/nvim/eval/funcs.c @@ -2463,7 +2463,7 @@ static void f_fnameescape(typval_T *argvars, typval_T *rettv, FunPtr fptr) static void f_fnamemodify(typval_T *argvars, typval_T *rettv, FunPtr fptr) { char_u *fbuf = NULL; - size_t len; + size_t len = 0; char buf[NUMBUFLEN]; const char *fname = tv_get_string_chk(&argvars[0]); const char *const mods = tv_get_string_buf_chk(&argvars[1], buf); @@ -2472,8 +2472,10 @@ static void f_fnamemodify(typval_T *argvars, typval_T *rettv, FunPtr fptr) } else { len = strlen(fname); size_t usedlen = 0; - (void)modify_fname((char_u *)mods, false, &usedlen, - (char_u **)&fname, &fbuf, &len); + if (mods != NULL && *mods != NUL) { + (void)modify_fname((char_u *)mods, false, &usedlen, + (char_u **)&fname, &fbuf, &len); + } } rettv->v_type = VAR_STRING; -- cgit From cb579bbaed9151c9958ed847d42d796438fe1120 Mon Sep 17 00:00:00 2001 From: Jan Edmund Lazo Date: Sun, 13 Dec 2020 15:56:56 -0500 Subject: vim-patch:8.1.1630: various small problems Problem: Various small problems. Solution: Various small improvements. https://github.com/vim/vim/commit/e809a4ed3014fbf717c936c727291b5f038829a5 --- src/nvim/eval/typval.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/nvim/eval/typval.h b/src/nvim/eval/typval.h index 1e3e9bd366..d8ede1e3ba 100644 --- a/src/nvim/eval/typval.h +++ b/src/nvim/eval/typval.h @@ -492,7 +492,7 @@ static inline void tv_list_ref(list_T *const l) static inline void tv_list_set_ret(typval_T *const tv, list_T *const l) REAL_FATTR_ALWAYS_INLINE REAL_FATTR_NONNULL_ARG(1); -/// Set a list as the return value +/// Set a list as the return value. Increments the reference count. /// /// @param[out] tv Object to receive the list /// @param[in,out] l List to pass to the object -- cgit