vim-patch:8.0.0274

Problem:    When update_single_line() is called recursively, or another screen
            update happens while it is busy, errors may occur.
Solution:   Check and update updating_screen. (Christian Brabandt)

070b33da93
This commit is contained in:
Justin M. Keyes 2017-02-04 17:36:39 +01:00
parent bb2f36d038
commit 1ec52b893a

View File

@ -487,9 +487,10 @@ void update_single_line(win_T *wp, linenr_T lnum)
int j;
// Don't do anything if the screen structures are (not yet) valid.
if (!screen_valid(true)) {
if (!screen_valid(true) || updating_screen) {
return;
}
updating_screen = true;
if (lnum >= wp->w_topline && lnum < wp->w_botline
&& foldedCount(wp, lnum, &win_foldinfo) == 0) {
@ -507,6 +508,7 @@ void update_single_line(win_T *wp, linenr_T lnum)
}
}
need_cursor_line_redraw = FALSE;
updating_screen = false;
}