Patch 8.1.1916
Problem: Trying to allocate negative amount of memory when closing a popup.
Solution: Check the rows are not out of bounds. Don't finish a selection if
it was never started.
Files: src/ui.c
*** ../vim-8.1.1915/src/ui.c 2019-08-20 20:13:40.334821916 +0200
--- src/ui.c 2019-08-24 14:07:17.867582852 +0200
***************
*** 1184,1190 ****
if (button == MOUSE_RELEASE)
{
! /* Check to make sure we have something selected */
if (cb->start.lnum == cb->end.lnum && cb->start.col == cb->end.col)
{
#ifdef FEAT_GUI
--- 1184,1193 ----
if (button == MOUSE_RELEASE)
{
! if (cb->state != SELECT_IN_PROGRESS)
! return;
!
! // Check to make sure we have something selected
if (cb->start.lnum == cb->end.lnum && cb->start.col == cb->end.col)
{
#ifdef FEAT_GUI
***************
*** 1591,1596 ****
--- 1594,1601 ----
col1 = clip_star.min_col;
if (col2 > clip_star.max_col)
col2 = clip_star.max_col;
+ if (row1 > clip_star.max_row || row2 < clip_star.min_row)
+ return;
if (row1 < clip_star.min_row)
row1 = clip_star.min_row;
if (row2 > clip_star.max_row)
*** ../vim-8.1.1915/src/version.c 2019-08-23 22:31:33.217176868 +0200
--- src/version.c 2019-08-24 14:12:04.778119113 +0200
***************
*** 763,764 ****
--- 763,766 ----
{ /* Add new patch number below this line */
+ /**/
+ 1916,
/**/
--
hundred-and-one symptoms of being an internet addict:
105. When someone asks you for your address, you tell them your URL.
/// Bram Moolenaar -- Br...@Moolenaar.net --
http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features --
http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language --
http://www.Zimbu.org ///
\\\ help me help AIDS victims --
http://ICCF-Holland.org ///