neovim

Neovim text editor
git clone https://git.dasho.dev/neovim.git
Log | Files | Refs | README

commit e884e460bcbac8ba353ba7136bb6c4620fbb0502
parent 1d160a76ec46e7eb4cfa627fb85987059fae55c4
Author: Famiu Haque <famiuhaque@protonmail.com>
Date:   Fri, 20 May 2022 23:03:06 +0600

fix: prevent crash when statusline expression sets value of 'winbar'

Closes #18649

Diffstat:
Msrc/nvim/screen.c | 5+++++
1 file changed, 5 insertions(+), 0 deletions(-)

diff --git a/src/nvim/screen.c b/src/nvim/screen.c @@ -5328,6 +5328,11 @@ static void win_redr_custom(win_T *wp, bool draw_winbar, bool draw_ruler) col = 0; grid = &wp->w_grid; grid_adjust(&grid, &row, &col); + + if (row < 0) { + return; + } + fillchar = wp->w_p_fcs_chars.wbr; attr = (wp == curwin) ? HL_ATTR(HLF_WBR) : HL_ATTR(HLF_WBRNC); maxwidth = wp->w_width_inner;