|
Karsten Hopp |
d5cd99 |
To: vim_dev@googlegroups.com
|
|
Karsten Hopp |
d5cd99 |
Subject: Patch 7.3.739
|
|
Karsten Hopp |
d5cd99 |
Fcc: outbox
|
|
Karsten Hopp |
d5cd99 |
From: Bram Moolenaar <Bram@moolenaar.net>
|
|
Karsten Hopp |
d5cd99 |
Mime-Version: 1.0
|
|
Karsten Hopp |
d5cd99 |
Content-Type: text/plain; charset=UTF-8
|
|
Karsten Hopp |
d5cd99 |
Content-Transfer-Encoding: 8bit
|
|
Karsten Hopp |
d5cd99 |
------------
|
|
Karsten Hopp |
d5cd99 |
|
|
Karsten Hopp |
d5cd99 |
Patch 7.3.739
|
|
Karsten Hopp |
d5cd99 |
Problem: Computing number of lines may have an integer overflow.
|
|
Karsten Hopp |
d5cd99 |
Solution: Check for MAXCOL explicitly. (Dominique Pelle)
|
|
Karsten Hopp |
d5cd99 |
Files: src/move.c
|
|
Karsten Hopp |
d5cd99 |
|
|
Karsten Hopp |
d5cd99 |
|
|
Karsten Hopp |
d5cd99 |
*** ../vim-7.3.738/src/move.c 2012-03-28 14:19:46.000000000 +0200
|
|
Karsten Hopp |
d5cd99 |
--- src/move.c 2012-11-28 18:15:42.000000000 +0100
|
|
Karsten Hopp |
d5cd99 |
***************
|
|
Karsten Hopp |
d5cd99 |
*** 2576,2582 ****
|
|
Karsten Hopp |
d5cd99 |
else
|
|
Karsten Hopp |
d5cd99 |
topline_back(lp);
|
|
Karsten Hopp |
d5cd99 |
h2 = lp->height;
|
|
Karsten Hopp |
d5cd99 |
! if (h2 + h1 > min_height)
|
|
Karsten Hopp |
d5cd99 |
{
|
|
Karsten Hopp |
d5cd99 |
*lp = loff0; /* no overlap */
|
|
Karsten Hopp |
d5cd99 |
return;
|
|
Karsten Hopp |
d5cd99 |
--- 2576,2582 ----
|
|
Karsten Hopp |
d5cd99 |
else
|
|
Karsten Hopp |
d5cd99 |
topline_back(lp);
|
|
Karsten Hopp |
d5cd99 |
h2 = lp->height;
|
|
Karsten Hopp |
d5cd99 |
! if (h2 == MAXCOL || h2 + h1 > min_height)
|
|
Karsten Hopp |
d5cd99 |
{
|
|
Karsten Hopp |
d5cd99 |
*lp = loff0; /* no overlap */
|
|
Karsten Hopp |
d5cd99 |
return;
|
|
Karsten Hopp |
d5cd99 |
***************
|
|
Karsten Hopp |
d5cd99 |
*** 2588,2594 ****
|
|
Karsten Hopp |
d5cd99 |
else
|
|
Karsten Hopp |
d5cd99 |
topline_back(lp);
|
|
Karsten Hopp |
d5cd99 |
h3 = lp->height;
|
|
Karsten Hopp |
d5cd99 |
! if (h3 + h2 > min_height)
|
|
Karsten Hopp |
d5cd99 |
{
|
|
Karsten Hopp |
d5cd99 |
*lp = loff0; /* no overlap */
|
|
Karsten Hopp |
d5cd99 |
return;
|
|
Karsten Hopp |
d5cd99 |
--- 2588,2594 ----
|
|
Karsten Hopp |
d5cd99 |
else
|
|
Karsten Hopp |
d5cd99 |
topline_back(lp);
|
|
Karsten Hopp |
d5cd99 |
h3 = lp->height;
|
|
Karsten Hopp |
d5cd99 |
! if (h3 == MAXCOL || h3 + h2 > min_height)
|
|
Karsten Hopp |
d5cd99 |
{
|
|
Karsten Hopp |
d5cd99 |
*lp = loff0; /* no overlap */
|
|
Karsten Hopp |
d5cd99 |
return;
|
|
Karsten Hopp |
d5cd99 |
***************
|
|
Karsten Hopp |
d5cd99 |
*** 2600,2606 ****
|
|
Karsten Hopp |
d5cd99 |
else
|
|
Karsten Hopp |
d5cd99 |
topline_back(lp);
|
|
Karsten Hopp |
d5cd99 |
h4 = lp->height;
|
|
Karsten Hopp |
d5cd99 |
! if (h4 + h3 + h2 > min_height || h3 + h2 + h1 > min_height)
|
|
Karsten Hopp |
d5cd99 |
*lp = loff1; /* 1 line overlap */
|
|
Karsten Hopp |
d5cd99 |
else
|
|
Karsten Hopp |
d5cd99 |
*lp = loff2; /* 2 lines overlap */
|
|
Karsten Hopp |
d5cd99 |
--- 2600,2606 ----
|
|
Karsten Hopp |
d5cd99 |
else
|
|
Karsten Hopp |
d5cd99 |
topline_back(lp);
|
|
Karsten Hopp |
d5cd99 |
h4 = lp->height;
|
|
Karsten Hopp |
d5cd99 |
! if (h4 == MAXCOL || h4 + h3 + h2 > min_height || h3 + h2 + h1 > min_height)
|
|
Karsten Hopp |
d5cd99 |
*lp = loff1; /* 1 line overlap */
|
|
Karsten Hopp |
d5cd99 |
else
|
|
Karsten Hopp |
d5cd99 |
*lp = loff2; /* 2 lines overlap */
|
|
Karsten Hopp |
d5cd99 |
*** ../vim-7.3.738/src/version.c 2012-11-28 17:41:55.000000000 +0100
|
|
Karsten Hopp |
d5cd99 |
--- src/version.c 2012-11-28 18:16:40.000000000 +0100
|
|
Karsten Hopp |
d5cd99 |
***************
|
|
Karsten Hopp |
d5cd99 |
*** 727,728 ****
|
|
Karsten Hopp |
d5cd99 |
--- 727,730 ----
|
|
Karsten Hopp |
d5cd99 |
{ /* Add new patch number below this line */
|
|
Karsten Hopp |
d5cd99 |
+ /**/
|
|
Karsten Hopp |
d5cd99 |
+ 739,
|
|
Karsten Hopp |
d5cd99 |
/**/
|
|
Karsten Hopp |
d5cd99 |
|
|
Karsten Hopp |
d5cd99 |
--
|
|
Karsten Hopp |
d5cd99 |
From "know your smileys":
|
|
Karsten Hopp |
d5cd99 |
!-| I-am-a-Cylon-Centurian-with-one-red-eye-bouncing-back-and-forth
|
|
Karsten Hopp |
d5cd99 |
|
|
Karsten Hopp |
d5cd99 |
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
|
|
Karsten Hopp |
d5cd99 |
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
|
|
Karsten Hopp |
d5cd99 |
\\\ an exciting new programming language -- http://www.Zimbu.org ///
|
|
Karsten Hopp |
d5cd99 |
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|