Skip to content

Commit c695cec

Browse files
committed
patch 8.0.0159: crash on startup when updating tabline
Problem: Using a NULL pointer when using feedkeys() to trigger drawing a tabline. Solution: Skip drawing a tabline if TabPageIdxs is NULL. (Dominique Pelle) Also fix recursing into getcmdline() from the cmd window.
1 parent 6247361 commit c695cec

File tree

3 files changed

+7
-1
lines changed

3 files changed

+7
-1
lines changed

src/ex_getln.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -772,7 +772,9 @@ getcmdline(
772772
/*
773773
* Open a window to edit the command line (and history).
774774
*/
775+
save_cmdline(&save_ccline);
775776
c = ex_window();
777+
restore_cmdline(&save_ccline);
776778
some_key_typed = TRUE;
777779
}
778780
}

src/screen.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3650,7 +3650,7 @@ win_line(
36503650
if (fdc > 0)
36513651
{
36523652
/* Draw the 'foldcolumn'. Allocate a buffer, "extra" may
3653-
* already be in used. */
3653+
* already be in use. */
36543654
p_extra_free = alloc(12 + 1);
36553655

36563656
if (p_extra_free != NULL)
@@ -10344,6 +10344,8 @@ draw_tabline(void)
1034410344
#endif
1034510345
);
1034610346

10347+
if (ScreenLines == NULL)
10348+
return;
1034710349
redraw_tabline = FALSE;
1034810350

1034910351
#ifdef FEAT_GUI_TABLINE

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -764,6 +764,8 @@ static char *(features[]) =
764764

765765
static int included_patches[] =
766766
{ /* Add new patch number below this line */
767+
/**/
768+
159,
767769
/**/
768770
158,
769771
/**/

0 commit comments

Comments
 (0)