From 655085204e36cdf91750db5e09ae3feb4884c670 Mon Sep 17 00:00:00 2001 From: Jan Edmund Lazo Date: Sun, 29 Sep 2019 09:29:16 -0400 Subject: vim-patch:8.1.0230: directly checking 'buftype' value Problem: Directly checking 'buftype' value. Solution: Add the bt_normal() function. (Yegappan Lakshmanan) https://github.com/vim/vim/commit/91335e5a67aaa9937e65f1e779b9f3f10fd33ee4 --- src/nvim/quickfix.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/nvim/quickfix.c') diff --git a/src/nvim/quickfix.c b/src/nvim/quickfix.c index 310b074cfb..0897367b2d 100644 --- a/src/nvim/quickfix.c +++ b/src/nvim/quickfix.c @@ -2140,7 +2140,7 @@ static win_T *qf_find_win_with_normal_buf(void) FUNC_ATTR_PURE FUNC_ATTR_WARN_UNUSED_RESULT { FOR_ALL_WINDOWS_IN_TAB(wp, curtab) { - if (wp->w_buffer->b_p_bt[0] == NUL) { + if (bt_normal(wp->w_buffer)) { return wp; } } @@ -2204,7 +2204,7 @@ static void qf_goto_win_with_ll_file(win_T *use_win, int qf_fnum, // Find a previous usable window win = curwin; do { - if (win->w_buffer->b_p_bt[0] == NUL) { + if (bt_normal(win->w_buffer)) { break; } if (win->w_prev == NULL) { @@ -2258,7 +2258,7 @@ static void qf_goto_win_with_qfl_file(int qf_fnum) // Remember a usable window. if (altwin == NULL && !win->w_p_pvw - && win->w_buffer->b_p_bt[0] == NUL) { + && bt_normal(win->w_buffer)) { altwin = win; } } -- cgit