]> granicus.if.org Git - vim/commitdiff
updated for version 7.4.442 v7.4.442
authorBram Moolenaar <Bram@vim.org>
Tue, 9 Sep 2014 21:11:49 +0000 (23:11 +0200)
committerBram Moolenaar <Bram@vim.org>
Tue, 9 Sep 2014 21:11:49 +0000 (23:11 +0200)
Problem:    Using unitinialized variable.
Solution:   Pass the first window of the tabpage.

src/eval.c
src/version.c

index 8303bd3759630e7aa004908c05cb22771d1b60fa..dfcb586b101d8e8fae35991738f669c1b30d35e5 100644 (file)
@@ -12071,7 +12071,7 @@ f_gettabvar(argvars, rettv)
     typval_T   *argvars;
     typval_T   *rettv;
 {
-    win_T      *win, *oldcurwin;
+    win_T      *oldcurwin;
     tabpage_T  *tp, *oldtabpage;
     dictitem_T *v;
     char_u     *varname;
@@ -12084,9 +12084,9 @@ f_gettabvar(argvars, rettv)
     tp = find_tabpage((int)get_tv_number_chk(&argvars[0], NULL));
     if (tp != NULL && varname != NULL)
     {
-       /* Set curwin to be our win, temporarily.  Also set the tabpage,
-        * otherwise the window is not valid. */
-       switch_win(&oldcurwin, &oldtabpage, win, tp, TRUE);
+       /* Set tp to be our tabpage, temporarily.  Also set the window to the
+        * first window in the tabpage, otherwise the window is not valid. */
+       switch_win(&oldcurwin, &oldtabpage, tp->tp_firstwin, tp, TRUE);
 
        /* look up the variable */
        /* Let gettabvar({nr}, "") return the "t:" dictionary. */
index 5d512a3cda76de9a8cedd5957ba199173deee6d7..70b40875529a849dca850b0e55f51a309e1d5c13 100644 (file)
@@ -741,6 +741,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    442,
 /**/
     441,
 /**/