|
Karsten Hopp |
400bed |
To: vim-dev@vim.org
|
|
Karsten Hopp |
400bed |
Subject: Patch 7.0.024
|
|
Karsten Hopp |
400bed |
Fcc: outbox
|
|
Karsten Hopp |
400bed |
From: Bram Moolenaar <Bram@moolenaar.net>
|
|
Karsten Hopp |
400bed |
Mime-Version: 1.0
|
|
Karsten Hopp |
400bed |
Content-Type: text/plain; charset=ISO-8859-1
|
|
Karsten Hopp |
400bed |
Content-Transfer-Encoding: 8bit
|
|
Karsten Hopp |
400bed |
------------
|
|
Karsten Hopp |
400bed |
|
|
Karsten Hopp |
400bed |
Patch 7.0.024
|
|
Karsten Hopp |
400bed |
Problem: It is possible to set arbitrary "v:" variables.
|
|
Karsten Hopp |
400bed |
Solution: Disallow setting "v:" variables that are not predefined.
|
|
Karsten Hopp |
400bed |
Files: src/eval.c
|
|
Karsten Hopp |
400bed |
|
|
Karsten Hopp |
400bed |
|
|
Karsten Hopp |
400bed |
*** ../vim-7.0.023/src/eval.c Sat May 13 13:36:47 2006
|
|
Karsten Hopp |
400bed |
--- src/eval.c Thu Jun 22 17:27:51 2006
|
|
Karsten Hopp |
400bed |
***************
|
|
Karsten Hopp |
400bed |
*** 17759,17764 ****
|
|
Karsten Hopp |
400bed |
--- 17763,17775 ----
|
|
Karsten Hopp |
400bed |
}
|
|
Karsten Hopp |
400bed |
else /* add a new variable */
|
|
Karsten Hopp |
400bed |
{
|
|
Karsten Hopp |
400bed |
+ /* Can't add "v:" variable. */
|
|
Karsten Hopp |
400bed |
+ if (ht == &vimvarht)
|
|
Karsten Hopp |
400bed |
+ {
|
|
Karsten Hopp |
400bed |
+ EMSG2(_(e_illvar), name);
|
|
Karsten Hopp |
400bed |
+ return;
|
|
Karsten Hopp |
400bed |
+ }
|
|
Karsten Hopp |
400bed |
+
|
|
Karsten Hopp |
400bed |
/* Make sure the variable name is valid. */
|
|
Karsten Hopp |
400bed |
for (p = varname; *p != NUL; ++p)
|
|
Karsten Hopp |
400bed |
if (!eval_isnamec1(*p) && (p == varname || !VIM_ISDIGIT(*p))
|
|
Karsten Hopp |
400bed |
*** ../vim-7.0.023/src/version.c Thu Jun 22 16:48:43 2006
|
|
Karsten Hopp |
400bed |
--- src/version.c Thu Jun 22 17:30:59 2006
|
|
Karsten Hopp |
400bed |
***************
|
|
Karsten Hopp |
400bed |
*** 668,669 ****
|
|
Karsten Hopp |
400bed |
--- 668,671 ----
|
|
Karsten Hopp |
400bed |
{ /* Add new patch number below this line */
|
|
Karsten Hopp |
400bed |
+ /**/
|
|
Karsten Hopp |
400bed |
+ 24,
|
|
Karsten Hopp |
400bed |
/**/
|
|
Karsten Hopp |
400bed |
|
|
Karsten Hopp |
400bed |
--
|
|
Karsten Hopp |
400bed |
ARTHUR: No, hang on! Just answer the five questions ...
|
|
Karsten Hopp |
400bed |
GALAHAD: Three questions ...
|
|
Karsten Hopp |
400bed |
ARTHUR: Three questions ... And we shall watch ... and pray.
|
|
Karsten Hopp |
400bed |
"Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD
|
|
Karsten Hopp |
400bed |
|
|
Karsten Hopp |
400bed |
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
|
|
Karsten Hopp |
400bed |
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
|
|
Karsten Hopp |
400bed |
\\\ download, build and distribute -- http://www.A-A-P.org ///
|
|
Karsten Hopp |
400bed |
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|