From 99b1163b5ae7a2f199803541c09f3da80547b40c Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Sat, 14 Oct 2023 18:39:24 +0800 Subject: vim-patch:9.0.2021: Coverity complains about change in charset (#25634) Problem: Coverity complains about change in charset (after v9.0.2017) Solution: check pointer t at index 0 closes: vim/vim#13322 https://github.com/vim/vim/commit/cd6ee6935811ab223605a3f39a550d26a617867d Co-authored-by: Christian Brabandt --- src/nvim/plines.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/nvim/plines.c b/src/nvim/plines.c index 2b8cdd4ad9..64dd3ff4d4 100644 --- a/src/nvim/plines.c +++ b/src/nvim/plines.c @@ -345,7 +345,7 @@ int win_lbr_chartabsize(chartabsize_T *cts, int *headp) // needs a break here if (wp->w_p_lbr && wp->w_p_wrap && wp->w_width_inner != 0) { char *t = cts->cts_line; - while (vim_isbreak((uint8_t)(*t))) { + while (vim_isbreak((uint8_t)t[0])) { t++; } vcol_start = (colnr_T)(t - cts->cts_line); -- cgit