Karsten Hopp 0a8aa0
To: vim-dev@vim.org
Karsten Hopp 0a8aa0
Subject: Patch 7.0.165
Karsten Hopp 0a8aa0
Fcc: outbox
Karsten Hopp 0a8aa0
From: Bram Moolenaar <Bram@moolenaar.net>
Karsten Hopp 0a8aa0
Mime-Version: 1.0
Karsten Hopp 0a8aa0
Content-Type: text/plain; charset=ISO-8859-1
Karsten Hopp 0a8aa0
Content-Transfer-Encoding: 8bit
Karsten Hopp 0a8aa0
------------
Karsten Hopp 0a8aa0
Karsten Hopp 0a8aa0
Patch 7.0.165
Karsten Hopp 0a8aa0
Problem:    Using CTRL-L at the search prompt adds a "/" and other characters
Karsten Hopp 0a8aa0
	    without escaping, causing the pattern not to match.
Karsten Hopp 0a8aa0
Solution:   Escape special characters with a backslash.
Karsten Hopp 0a8aa0
Files:	    src/ex_getln.c
Karsten Hopp 0a8aa0
Karsten Hopp 0a8aa0
Karsten Hopp 0a8aa0
*** ../vim-7.0.164/src/ex_getln.c	Tue Oct 17 16:26:52 2006
Karsten Hopp 0a8aa0
--- src/ex_getln.c	Tue Nov 14 21:36:13 2006
Karsten Hopp 0a8aa0
***************
Karsten Hopp 0a8aa0
*** 34,40 ****
Karsten Hopp 0a8aa0
      int		xp_context;	/* type of expansion */
Karsten Hopp 0a8aa0
  # ifdef FEAT_EVAL
Karsten Hopp 0a8aa0
      char_u	*xp_arg;	/* user-defined expansion arg */
Karsten Hopp 0a8aa0
!     int		input_fn;	/* Invoked for input() function */
Karsten Hopp 0a8aa0
  # endif
Karsten Hopp 0a8aa0
  };
Karsten Hopp 0a8aa0
  
Karsten Hopp 0a8aa0
--- 34,40 ----
Karsten Hopp 0a8aa0
      int		xp_context;	/* type of expansion */
Karsten Hopp 0a8aa0
  # ifdef FEAT_EVAL
Karsten Hopp 0a8aa0
      char_u	*xp_arg;	/* user-defined expansion arg */
Karsten Hopp 0a8aa0
!     int		input_fn;	/* when TRUE Invoked for input() function */
Karsten Hopp 0a8aa0
  # endif
Karsten Hopp 0a8aa0
  };
Karsten Hopp 0a8aa0
  
Karsten Hopp 0a8aa0
***************
Karsten Hopp 0a8aa0
*** 1390,1396 ****
Karsten Hopp 0a8aa0
--- 1390,1406 ----
Karsten Hopp 0a8aa0
  		    {
Karsten Hopp 0a8aa0
  			c = gchar_cursor();
Karsten Hopp 0a8aa0
  			if (c != NUL)
Karsten Hopp 0a8aa0
+ 			{
Karsten Hopp 0a8aa0
+ 			    if (c == firstc || vim_strchr((char_u *)(
Karsten Hopp 0a8aa0
+ 					    p_magic ? "\\^$.*[" : "\\^$"), c)
Karsten Hopp 0a8aa0
+ 								      != NULL)
Karsten Hopp 0a8aa0
+ 			    {
Karsten Hopp 0a8aa0
+ 				/* put a backslash before special characters */
Karsten Hopp 0a8aa0
+ 				stuffcharReadbuff(c);
Karsten Hopp 0a8aa0
+ 				c = '\\';
Karsten Hopp 0a8aa0
+ 			    }
Karsten Hopp 0a8aa0
  			    break;
Karsten Hopp 0a8aa0
+ 			}
Karsten Hopp 0a8aa0
  		    }
Karsten Hopp 0a8aa0
  		    goto cmdline_not_changed;
Karsten Hopp 0a8aa0
  		}
Karsten Hopp 0a8aa0
*** ../vim-7.0.164/src/version.c	Tue Nov 14 20:24:32 2006
Karsten Hopp 0a8aa0
--- src/version.c	Tue Nov 21 11:28:43 2006
Karsten Hopp 0a8aa0
***************
Karsten Hopp 0a8aa0
*** 668,669 ****
Karsten Hopp 0a8aa0
--- 668,671 ----
Karsten Hopp 0a8aa0
  {   /* Add new patch number below this line */
Karsten Hopp 0a8aa0
+ /**/
Karsten Hopp 0a8aa0
+     165,
Karsten Hopp 0a8aa0
  /**/
Karsten Hopp 0a8aa0
Karsten Hopp 0a8aa0
-- 
Karsten Hopp 0a8aa0
       He was not in the least bit scared to be mashed into a pulp
Karsten Hopp 0a8aa0
       Or to have his eyes gouged out and his elbows broken;
Karsten Hopp 0a8aa0
       To have his kneecaps split and his body burned away
Karsten Hopp 0a8aa0
       And his limbs all hacked and mangled, brave Sir Robin.
Karsten Hopp 0a8aa0
                 "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD
Karsten Hopp 0a8aa0
Karsten Hopp 0a8aa0
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
Karsten Hopp 0a8aa0
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
Karsten Hopp 0a8aa0
\\\        download, build and distribute -- http://www.A-A-P.org        ///
Karsten Hopp 0a8aa0
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///