summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2008-06-27 18:26:11 +0000
committerBram Moolenaar <Bram@vim.org>2008-06-27 18:26:11 +0000
commit632deedd0fe559b50d5292ef00e0241dc16d511c (patch)
tree82292b1f40cc87e3762494dc3298fdfdb8197179 /src
parent00ca284cc0996c183f25213d307fcf8b2ce0abee (diff)
downloadvim-git-632deedd0fe559b50d5292ef00e0241dc16d511c.tar.gz
updated for version 7.2a-002v7.2a.002
Diffstat (limited to 'src')
-rw-r--r--src/eval.c18
-rw-r--r--src/version.c2
2 files changed, 10 insertions, 10 deletions
diff --git a/src/eval.c b/src/eval.c
index fada51d64..67880cfb7 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -10442,17 +10442,12 @@ f_getbufvar(argvars, rettv)
if (buf != NULL && varname != NULL)
{
- if (*varname == '&') /* buffer-local-option */
- {
- /* set curbuf to be our buf, temporarily */
- save_curbuf = curbuf;
- curbuf = buf;
+ /* set curbuf to be our buf, temporarily */
+ save_curbuf = curbuf;
+ curbuf = buf;
+ if (*varname == '&') /* buffer-local-option */
get_option_tv(&varname, rettv, TRUE);
-
- /* restore previous notion of curbuf */
- curbuf = save_curbuf;
- }
else
{
if (*varname == NUL)
@@ -10461,10 +10456,13 @@ f_getbufvar(argvars, rettv)
* find_var_in_ht(). */
varname = (char_u *)"b:" + 2;
/* look up the variable */
- v = find_var_in_ht(&buf->b_vars.dv_hashtab, varname, FALSE);
+ v = find_var_in_ht(&curbuf->b_vars.dv_hashtab, varname, FALSE);
if (v != NULL)
copy_tv(&v->di_tv, rettv);
}
+
+ /* restore previous notion of curbuf */
+ curbuf = save_curbuf;
}
--emsg_off;
diff --git a/src/version.c b/src/version.c
index c8565c447..6730cc0fd 100644
--- a/src/version.c
+++ b/src/version.c
@@ -677,6 +677,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 2,
+/**/
1,
/**/
0