| To: vim_dev@googlegroups.com |
| Subject: Patch 7.4.834 |
| Fcc: outbox |
| From: Bram Moolenaar <Bram@moolenaar.net> |
| Mime-Version: 1.0 |
| Content-Type: text/plain; charset=UTF-8 |
| Content-Transfer-Encoding: 8bit |
| |
| |
| Patch 7.4.834 |
| Problem: gettabvar() doesn't work after Vim start. (Szymon Wrozynski) |
| Solution: Handle first window in tab still being NULL. (Christian Brabandt) |
| Files: src/eval.c, src/testdir/test91.in, src/testdir/test91.ok |
| |
| |
| |
| |
| |
| *** 12291,12297 **** |
| { |
| /* 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, tp, TRUE) |
| == OK) |
| { |
| /* look up the variable */ |
| --- 12291,12298 ---- |
| { |
| /* 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) |
| { |
| /* look up the variable */ |
| |
| |
| |
| *** 5,12 **** |
| :so small.vim |
| :so mbyte.vim |
| :" |
| - :" Test for getbufvar() |
| :" Use strings to test for memory leaks. |
| :let b:var_num = '1234' |
| :let def_num = '5678' |
| :$put =string(getbufvar(1, 'var_num')) |
| --- 5,16 ---- |
| :so small.vim |
| :so mbyte.vim |
| :" |
| :" Use strings to test for memory leaks. |
| + :" First, check that in an empty window, gettabvar() returns the correct value |
| + :let t:testvar='abcd' |
| + :$put =string(gettabvar(1,'testvar')) |
| + :$put =string(gettabvar(1,'testvar')) |
| + :" Test for getbufvar() |
| :let b:var_num = '1234' |
| :let def_num = '5678' |
| :$put =string(getbufvar(1, 'var_num')) |
| |
| |
| |
| *** 1,4 **** |
| --- 1,6 ---- |
| start: |
| + 'abcd' |
| + 'abcd' |
| '1234' |
| '1234' |
| {'var_num': '1234'} |
| |
| |
| |
| *** 743,744 **** |
| --- 743,746 ---- |
| { /* Add new patch number below this line */ |
| + /**/ |
| + 834, |
| /**/ |
| |
| -- |
| A special law prohibits unmarried women from parachuting on Sunday or she |
| shall risk arrest, fine, and/or jailing. |
| [real standing law in Florida, United States of America] |
| |
| /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ |
| /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ |
| \\\ an exciting new programming language -- http://www.Zimbu.org /// |
| \\\ help me help AIDS victims -- http://ICCF-Holland.org /// |