diff options
author | Jan Edmund Lazo <jan.lazo@mail.utoronto.ca> | 2021-03-28 13:54:28 -0400 |
---|---|---|
committer | Jan Edmund Lazo <jan.lazo@mail.utoronto.ca> | 2021-03-29 18:29:25 -0400 |
commit | 375f957af65509bcf80c073362fae1d95bb32380 (patch) | |
tree | 9052916efcbf0efe9a3040b17091142ccff0aa6f /src/nvim/buffer.c | |
parent | 3dbcf69888b0f44c06b9ede3928fcd9d68f65739 (diff) | |
download | rneovim-375f957af65509bcf80c073362fae1d95bb32380.tar.gz rneovim-375f957af65509bcf80c073362fae1d95bb32380.tar.bz2 rneovim-375f957af65509bcf80c073362fae1d95bb32380.zip |
vim-patch:8.1.0989: various small code ugliness
Problem: Various small code ugliness.
Solution: Remove pointless NULL checks. Fix function calls. Fix typos.
(Dominique Pelle, closes vim/vim#4060)
https://github.com/vim/vim/commit/bdace838c67c1bd94e55e34270a8325933891466
Diffstat (limited to 'src/nvim/buffer.c')
-rw-r--r-- | src/nvim/buffer.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/nvim/buffer.c b/src/nvim/buffer.c index cc9f130bfc..c7ec3a456c 100644 --- a/src/nvim/buffer.c +++ b/src/nvim/buffer.c @@ -1947,13 +1947,9 @@ void free_buf_options(buf_T *buf, int free_p_ff) clear_string_option(&buf->b_p_flp); clear_string_option(&buf->b_p_isk); clear_string_option(&buf->b_p_vsts); - if (buf->b_p_vsts_nopaste) { - xfree(buf->b_p_vsts_nopaste); - } + xfree(buf->b_p_vsts_nopaste); buf->b_p_vsts_nopaste = NULL; - if (buf->b_p_vsts_array) { - xfree(buf->b_p_vsts_array); - } + xfree(buf->b_p_vsts_array); buf->b_p_vsts_array = NULL; clear_string_option(&buf->b_p_vts); XFREE_CLEAR(buf->b_p_vts_array); |