astepano / rpms / vim

Forked from rpms/vim 6 years ago
Clone
8be7ca4
To: vim_dev@googlegroups.com
8be7ca4
Subject: Patch 7.3.242
8be7ca4
Fcc: outbox
8be7ca4
From: Bram Moolenaar <Bram@moolenaar.net>
8be7ca4
Mime-Version: 1.0
8be7ca4
Content-Type: text/plain; charset=UTF-8
8be7ca4
Content-Transfer-Encoding: 8bit
8be7ca4
------------
8be7ca4
8be7ca4
Patch 7.3.242
8be7ca4
Problem:    Illegal memory access in after_pathsep().
8be7ca4
Solution:   Check that the pointer is not at the start of the file name.
8be7ca4
	    (Dominique Pelle)
8be7ca4
Files:	    src/misc2.c
8be7ca4
8be7ca4
8be7ca4
*** ../vim-7.3.241/src/misc2.c	2011-07-07 16:20:45.000000000 +0200
8be7ca4
--- src/misc2.c	2011-07-07 17:05:41.000000000 +0200
8be7ca4
***************
8be7ca4
*** 3247,3253 ****
8be7ca4
  #if defined(FEAT_MBYTE) || defined(PROTO)
8be7ca4
  /*
8be7ca4
   * Return TRUE if "p" points to just after a path separator.
8be7ca4
!  * Take care of multi-byte characters.
8be7ca4
   * "b" must point to the start of the file name
8be7ca4
   */
8be7ca4
      int
8be7ca4
--- 3247,3253 ----
8be7ca4
  #if defined(FEAT_MBYTE) || defined(PROTO)
8be7ca4
  /*
8be7ca4
   * Return TRUE if "p" points to just after a path separator.
8be7ca4
!  * Takes care of multi-byte characters.
8be7ca4
   * "b" must point to the start of the file name
8be7ca4
   */
8be7ca4
      int
8be7ca4
***************
8be7ca4
*** 3255,3261 ****
8be7ca4
      char_u	*b;
8be7ca4
      char_u	*p;
8be7ca4
  {
8be7ca4
!     return vim_ispathsep(p[-1])
8be7ca4
  			     && (!has_mbyte || (*mb_head_off)(b, p - 1) == 0);
8be7ca4
  }
8be7ca4
  #endif
8be7ca4
--- 3255,3261 ----
8be7ca4
      char_u	*b;
8be7ca4
      char_u	*p;
8be7ca4
  {
8be7ca4
!     return p > b && vim_ispathsep(p[-1])
8be7ca4
  			     && (!has_mbyte || (*mb_head_off)(b, p - 1) == 0);
8be7ca4
  }
8be7ca4
  #endif
8be7ca4
*** ../vim-7.3.241/src/version.c	2011-07-07 16:44:33.000000000 +0200
8be7ca4
--- src/version.c	2011-07-07 17:05:49.000000000 +0200
8be7ca4
***************
8be7ca4
*** 711,712 ****
8be7ca4
--- 711,714 ----
8be7ca4
  {   /* Add new patch number below this line */
8be7ca4
+ /**/
8be7ca4
+     242,
8be7ca4
  /**/
8be7ca4
8be7ca4
-- 
8be7ca4
hundred-and-one symptoms of being an internet addict:
8be7ca4
260. Co-workers have to E-mail you about the fire alarm to get
8be7ca4
     you out of the building.
8be7ca4
8be7ca4
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
8be7ca4
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
8be7ca4
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
8be7ca4
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///