changeset 6795:adb3699fa30c v7.4.719

patch 7.4.719 Problem: Overflow when adding MAXCOL to a pointer. Solution: Subtract pointers instead. (James McCoy)
author Bram Moolenaar <bram@vim.org>
date Mon, 04 May 2015 16:10:26 +0200
parents 0598637d7276
children 24d91496a2b2
files src/screen.c src/version.c
diffstat 2 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/screen.c
+++ b/src/screen.c
@@ -4341,7 +4341,7 @@ win_line(wp, lnum, startrow, endrow, noc
 			  || (mb_utf8 && mb_c == 160)
 #endif
 			 ) && lcs_nbsp)
-			|| (c == ' ' && lcs_space && ptr <= line + trailcol)))
+			|| (c == ' ' && lcs_space && ptr - line <= trailcol)))
 	    {
 		c = (c == ' ') ? lcs_space : lcs_nbsp;
 		if (area_attr == 0 && search_attr == 0)
--- a/src/version.c
+++ b/src/version.c
@@ -742,6 +742,8 @@ static char *(features[]) =
 static int included_patches[] =
 {   /* Add new patch number below this line */
 /**/
+    719,
+/**/
     718,
 /**/
     717,