diff options
author | zeertzjq <zeertzjq@outlook.com> | 2025-02-03 13:20:48 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-02-03 05:20:48 +0000 |
commit | 3a2893015759396e5345a1a85e0427705e0570b4 (patch) | |
tree | 24228ce9af169ca2d29083b49a18e66d3e7f1564 /src/nvim/option.c | |
parent | 0c8890e7a771ca26c75a767b9851aaf7bf2c0f90 (diff) | |
download | rneovim-3a2893015759396e5345a1a85e0427705e0570b4.tar.gz rneovim-3a2893015759396e5345a1a85e0427705e0570b4.tar.bz2 rneovim-3a2893015759396e5345a1a85e0427705e0570b4.zip |
vim-patch:9.0.1391: "clear" macros are not always used (#32312)
Problem: "clear" macros are not always used.
Solution: Use ALLOC_ONE, VIM_CLEAR, CLEAR_POINTER and CLEAR_FIELD in more
places. (Yegappan Lakshmanan, closes vim/vim#12104)
https://github.com/vim/vim/commit/960dcbd098c761dd623bec9492d5391ff6e8dceb
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Diffstat (limited to 'src/nvim/option.c')
-rw-r--r-- | src/nvim/option.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/option.c b/src/nvim/option.c index f9eb67ff83..796165453c 100644 --- a/src/nvim/option.c +++ b/src/nvim/option.c @@ -5226,7 +5226,7 @@ void buf_copy_options(buf_T *buf, int flags) // or to a help buffer. if (dont_do_help) { buf->b_p_isk = save_p_isk; - if (p_vts && p_vts != empty_string_option && !buf->b_p_vts_array) { + if (p_vts && *p_vts != NUL && !buf->b_p_vts_array) { tabstop_set(p_vts, &buf->b_p_vts_array); } else { buf->b_p_vts_array = NULL; @@ -5239,7 +5239,7 @@ void buf_copy_options(buf_T *buf, int flags) COPY_OPT_SCTX(buf, kBufOptTabstop); buf->b_p_vts = xstrdup(p_vts); COPY_OPT_SCTX(buf, kBufOptVartabstop); - if (p_vts && p_vts != empty_string_option && !buf->b_p_vts_array) { + if (p_vts && *p_vts != NUL && !buf->b_p_vts_array) { tabstop_set(p_vts, &buf->b_p_vts_array); } else { buf->b_p_vts_array = NULL; |