Karsten Hopp 19a296
To: vim_dev@googlegroups.com
Karsten Hopp 19a296
Subject: Patch 7.3.573
Karsten Hopp 19a296
Fcc: outbox
Karsten Hopp 19a296
From: Bram Moolenaar <Bram@moolenaar.net>
Karsten Hopp 19a296
Mime-Version: 1.0
Karsten Hopp 19a296
Content-Type: text/plain; charset=UTF-8
Karsten Hopp 19a296
Content-Transfer-Encoding: 8bit
Karsten Hopp 19a296
------------
Karsten Hopp 19a296
Karsten Hopp 19a296
Patch 7.3.573
Karsten Hopp 19a296
Problem:    Using array index before bounds checking.
Karsten Hopp 19a296
Solution:   Swap the parts of the condition. (Dominique Pelle)
Karsten Hopp 19a296
Files:	    src/ops.c
Karsten Hopp 19a296
Karsten Hopp 19a296
Karsten Hopp 19a296
*** ../vim-7.3.572/src/ops.c	2012-06-13 17:28:51.000000000 +0200
Karsten Hopp 19a296
--- src/ops.c	2012-06-29 13:27:11.000000000 +0200
Karsten Hopp 19a296
***************
Karsten Hopp 19a296
*** 6458,6464 ****
Karsten Hopp 19a296
      long	chars = 0;
Karsten Hopp 19a296
      int		is_word = 0;
Karsten Hopp 19a296
  
Karsten Hopp 19a296
!     for (i = 0; line[i] && i < limit; )
Karsten Hopp 19a296
      {
Karsten Hopp 19a296
  	if (is_word)
Karsten Hopp 19a296
  	{
Karsten Hopp 19a296
--- 6458,6464 ----
Karsten Hopp 19a296
      long	chars = 0;
Karsten Hopp 19a296
      int		is_word = 0;
Karsten Hopp 19a296
  
Karsten Hopp 19a296
!     for (i = 0; i < limit && line[i] != NUL; )
Karsten Hopp 19a296
      {
Karsten Hopp 19a296
  	if (is_word)
Karsten Hopp 19a296
  	{
Karsten Hopp 19a296
*** ../vim-7.3.572/src/version.c	2012-06-29 13:19:23.000000000 +0200
Karsten Hopp 19a296
--- src/version.c	2012-06-29 13:27:59.000000000 +0200
Karsten Hopp 19a296
***************
Karsten Hopp 19a296
*** 716,717 ****
Karsten Hopp 19a296
--- 716,719 ----
Karsten Hopp 19a296
  {   /* Add new patch number below this line */
Karsten Hopp 19a296
+ /**/
Karsten Hopp 19a296
+     573,
Karsten Hopp 19a296
  /**/
Karsten Hopp 19a296
Karsten Hopp 19a296
-- 
Karsten Hopp 19a296
"Thou shalt not follow the Null Pointer, for at its end Chaos and
Karsten Hopp 19a296
Madness lie."
Karsten Hopp 19a296
Karsten Hopp 19a296
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
Karsten Hopp 19a296
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
Karsten Hopp 19a296
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
Karsten Hopp 19a296
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///