From 7746f641b89d1d80b2121980f83ae1f322c30e89 Mon Sep 17 00:00:00 2001 From: bfredl Date: Tue, 4 Oct 2022 11:28:30 +0200 Subject: fix(options): no matter what is said, 'cmdheight' is tab-local (susy baka) --- src/nvim/window.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) (limited to 'src/nvim/window.c') diff --git a/src/nvim/window.c b/src/nvim/window.c index c3806e10ff..c0edef7abc 100644 --- a/src/nvim/window.c +++ b/src/nvim/window.c @@ -3865,13 +3865,12 @@ void close_others(int message, int forceit) } // Allocate the first window and put an empty buffer in it. -// Called from main(). -// -// Return FAIL when something goes wrong. -int win_alloc_first(void) +// Only called from main(). +void win_alloc_first(void) { if (win_alloc_firstwin(NULL) == FAIL) { - return FAIL; + // allocating first buffer before any autocmds should not fail. + abort(); } first_tabpage = alloc_tabpage(); @@ -3880,8 +3879,6 @@ int win_alloc_first(void) curtab->tp_firstwin = firstwin; curtab->tp_lastwin = lastwin; curtab->tp_curwin = curwin; - - return OK; } // Init `aucmd_win`. This can only be done after the first window -- cgit