0
0
mirror of https://github.com/vim/vim.git synced 2025-10-14 07:04:10 -04:00

patch 8.0.1160: getting tab-local variable fails after closing window

Problem:    Getting tab-local variable fails after closing window.
Solution:   set tp_firstwin and tp_lastwin. (Jason Franklin, closes #2170)
This commit is contained in:
Bram Moolenaar
2017-09-29 21:29:18 +02:00
parent d371bbe0ab
commit 816968defc
4 changed files with 28 additions and 9 deletions

View File

@@ -5183,8 +5183,8 @@ f_gettabvar(typval_T *argvars, typval_T *rettv)
/* Set tp to be our tabpage, temporarily. Also set the window to the
* first window in the tabpage, otherwise the window is not valid. */
if (switch_win(&oldcurwin, &oldtabpage,
tp->tp_firstwin == NULL ? firstwin : tp->tp_firstwin, tp, TRUE)
== OK)
tp == curtab || tp->tp_firstwin == NULL ? firstwin
: tp->tp_firstwin, tp, TRUE) == OK)
{
/* look up the variable */
/* Let gettabvar({nr}, "") return the "t:" dictionary. */