]> git.ipfire.org Git - thirdparty/vim.git/commitdiff
updated for version 7.3.739 v7.3.739
authorBram Moolenaar <Bram@vim.org>
Wed, 28 Nov 2012 17:22:11 +0000 (18:22 +0100)
committerBram Moolenaar <Bram@vim.org>
Wed, 28 Nov 2012 17:22:11 +0000 (18:22 +0100)
Problem:    Computing number of lines may have an integer overflow.
Solution:   Check for MAXCOL explicitly. (Dominique Pelle)

src/move.c
src/version.c

index 21a74b8adceedea0d533de886e593581a07da2bf..5c8257449c16c6f378074fda21c8c18c7893a824 100644 (file)
@@ -2576,7 +2576,7 @@ get_scroll_overlap(lp, dir)
     else
        topline_back(lp);
     h2 = lp->height;
-    if (h2 + h1 > min_height)
+    if (h2 == MAXCOL || h2 + h1 > min_height)
     {
        *lp = loff0;    /* no overlap */
        return;
@@ -2588,7 +2588,7 @@ get_scroll_overlap(lp, dir)
     else
        topline_back(lp);
     h3 = lp->height;
-    if (h3 + h2 > min_height)
+    if (h3 == MAXCOL || h3 + h2 > min_height)
     {
        *lp = loff0;    /* no overlap */
        return;
@@ -2600,7 +2600,7 @@ get_scroll_overlap(lp, dir)
     else
        topline_back(lp);
     h4 = lp->height;
-    if (h4 + h3 + h2 > min_height || h3 + h2 + h1 > min_height)
+    if (h4 == MAXCOL || h4 + h3 + h2 > min_height || h3 + h2 + h1 > min_height)
        *lp = loff1;    /* 1 line overlap */
     else
        *lp = loff2;    /* 2 lines overlap */
index a6259c6263a10ba37b1305bbc7b4ee07ab975aa8..47a69c28ed6fe5b3db7c3f3dd8bd4ad17f7af8a4 100644 (file)
@@ -725,6 +725,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    739,
 /**/
     738,
 /**/