|
Karsten Hopp |
f6dd7f |
To: vim-dev@vim.org
|
|
Karsten Hopp |
f6dd7f |
Subject: Patch 7.0.120
|
|
Karsten Hopp |
f6dd7f |
Fcc: outbox
|
|
Karsten Hopp |
f6dd7f |
From: Bram Moolenaar <Bram@moolenaar.net>
|
|
Karsten Hopp |
f6dd7f |
Mime-Version: 1.0
|
|
Karsten Hopp |
f6dd7f |
Content-Type: text/plain; charset=ISO-8859-1
|
|
Karsten Hopp |
f6dd7f |
Content-Transfer-Encoding: 8bit
|
|
Karsten Hopp |
f6dd7f |
------------
|
|
Karsten Hopp |
f6dd7f |
|
|
Karsten Hopp |
f6dd7f |
Patch 7.0.120
|
|
Karsten Hopp |
f6dd7f |
Problem: Crash when using CTRL-R = at the command line and entering
|
|
Karsten Hopp |
f6dd7f |
"getreg('=')". (James Vega)
|
|
Karsten Hopp |
f6dd7f |
Solution: Avoid recursiveness of evaluating the = register.
|
|
Karsten Hopp |
f6dd7f |
Files: src/ops.c
|
|
Karsten Hopp |
f6dd7f |
|
|
Karsten Hopp |
f6dd7f |
|
|
Karsten Hopp |
f6dd7f |
*** ../vim-7.0.119/src/ops.c Sun Jul 23 22:37:29 2006
|
|
Karsten Hopp |
f6dd7f |
--- src/ops.c Fri Oct 6 21:27:40 2006
|
|
Karsten Hopp |
f6dd7f |
***************
|
|
Karsten Hopp |
f6dd7f |
*** 770,775 ****
|
|
Karsten Hopp |
f6dd7f |
--- 770,776 ----
|
|
Karsten Hopp |
f6dd7f |
{
|
|
Karsten Hopp |
f6dd7f |
char_u *expr_copy;
|
|
Karsten Hopp |
f6dd7f |
char_u *rv;
|
|
Karsten Hopp |
f6dd7f |
+ static int nested = 0;
|
|
Karsten Hopp |
f6dd7f |
|
|
Karsten Hopp |
f6dd7f |
if (expr_line == NULL)
|
|
Karsten Hopp |
f6dd7f |
return NULL;
|
|
Karsten Hopp |
f6dd7f |
***************
|
|
Karsten Hopp |
f6dd7f |
*** 780,786 ****
|
|
Karsten Hopp |
f6dd7f |
--- 781,794 ----
|
|
Karsten Hopp |
f6dd7f |
if (expr_copy == NULL)
|
|
Karsten Hopp |
f6dd7f |
return NULL;
|
|
Karsten Hopp |
f6dd7f |
|
|
Karsten Hopp |
f6dd7f |
+ /* When we are invoked recursively limit the evaluation to 10 levels.
|
|
Karsten Hopp |
f6dd7f |
+ * Then return the string as-is. */
|
|
Karsten Hopp |
f6dd7f |
+ if (nested >= 10)
|
|
Karsten Hopp |
f6dd7f |
+ return expr_copy;
|
|
Karsten Hopp |
f6dd7f |
+
|
|
Karsten Hopp |
f6dd7f |
+ ++nested;
|
|
Karsten Hopp |
f6dd7f |
rv = eval_to_string(expr_copy, NULL, TRUE);
|
|
Karsten Hopp |
f6dd7f |
+ --nested;
|
|
Karsten Hopp |
f6dd7f |
vim_free(expr_copy);
|
|
Karsten Hopp |
f6dd7f |
return rv;
|
|
Karsten Hopp |
f6dd7f |
}
|
|
Karsten Hopp |
f6dd7f |
*** ../vim-7.0.119/src/version.c Fri Oct 6 20:39:58 2006
|
|
Karsten Hopp |
f6dd7f |
--- src/version.c Fri Oct 6 21:31:56 2006
|
|
Karsten Hopp |
f6dd7f |
***************
|
|
Karsten Hopp |
f6dd7f |
*** 668,669 ****
|
|
Karsten Hopp |
f6dd7f |
--- 668,671 ----
|
|
Karsten Hopp |
f6dd7f |
{ /* Add new patch number below this line */
|
|
Karsten Hopp |
f6dd7f |
+ /**/
|
|
Karsten Hopp |
f6dd7f |
+ 120,
|
|
Karsten Hopp |
f6dd7f |
/**/
|
|
Karsten Hopp |
f6dd7f |
|
|
Karsten Hopp |
f6dd7f |
--
|
|
Karsten Hopp |
f6dd7f |
hundred-and-one symptoms of being an internet addict:
|
|
Karsten Hopp |
f6dd7f |
16. You step out of your room and realize that your parents have moved and
|
|
Karsten Hopp |
f6dd7f |
you don't have a clue when it happened.
|
|
Karsten Hopp |
f6dd7f |
|
|
Karsten Hopp |
f6dd7f |
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
|
|
Karsten Hopp |
f6dd7f |
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
|
|
Karsten Hopp |
f6dd7f |
\\\ download, build and distribute -- http://www.A-A-P.org ///
|
|
Karsten Hopp |
f6dd7f |
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|