Patch 8.2.0880

8 views
Skip to first unread message

Bram Moolenaar

unread,
Jun 1, 2020, 1:09:35 PM6/1/20
to vim...@googlegroups.com

Patch 8.2.0880 (after 8.2.0877)
Problem: Leaking memory when using searchcount().
Solution: Free the last used search pattern.
Files: src/search.c


*** ../vim-8.2.0879/src/search.c 2020-06-01 18:55:58.781697123 +0200
--- src/search.c 2020-06-01 19:07:10.812438216 +0200
***************
*** 4147,4152 ****
--- 4147,4153 ----
{
if (*pattern == NUL)
goto the_end;
+ vim_free(spats[last_idx].pat);
spats[last_idx].pat = vim_strsave(pattern);
}
if (spats[last_idx].pat == NULL || *spats[last_idx].pat == NUL)
*** ../vim-8.2.0879/src/version.c 2020-06-01 18:55:58.781697123 +0200
--- src/version.c 2020-06-01 19:08:38.408281962 +0200
***************
*** 748,749 ****
--- 748,751 ----
{ /* Add new patch number below this line */
+ /**/
+ 880,
/**/

--
hundred-and-one symptoms of being an internet addict:
245. You use Real Audio to listen to a radio station from a distant
city rather than turn on your stereo system.

/// 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 ///
Reply all
Reply to author
Forward
0 new messages