Patch 9.0.0413
Problem: ASAN reports a memory leak.
Solution: Free the string received from the server. (Ken Takata,
closes #11080)
Files: src/clientserver.c
*** ../vim-9.0.0412/src/clientserver.c 2022-03-22 20:38:51.000000000 +0000
--- src/clientserver.c 2022-09-08 10:53:49.638937733 +0100
***************
*** 423,431 ****
if (argtype == ARGTYPE_EDIT_WAIT)
{
int numFiles = *argc - i - 1;
- int j;
char_u *done = alloc(numFiles);
- char_u *p;
# ifdef FEAT_GUI_MSWIN
NOTIFYICONDATA ni;
int count = 0;
--- 423,429 ----
***************
*** 450,455 ****
--- 448,455 ----
vim_memset(done, 0, numFiles);
while (memchr(done, 0, numFiles) != NULL)
{
+ char_u *p;
+ int j;
# ifdef MSWIN
p = serverGetReply(srv, NULL, TRUE, TRUE, 0);
if (p == NULL)
***************
*** 459,464 ****
--- 459,465 ----
break;
# endif
j = atoi((char *)p);
+ vim_free(p);
if (j >= 0 && j < numFiles)
{
# ifdef FEAT_GUI_MSWIN
*** ../vim-9.0.0412/src/version.c 2022-09-07 21:46:48.733219019 +0100
--- src/version.c 2022-09-08 10:55:06.306105719 +0100
***************
*** 705,706 ****
--- 705,708 ----
{ /* Add new patch number below this line */
+ /**/
+ 413,
/**/
--
How To Keep A Healthy Level Of Insanity:
5. Put decaf in the coffee maker for 3 weeks. Once everyone has gotten
over their caffeine addictions, switch to espresso.
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// \\\
\\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/vim_dev/20220908095815.535E41C0B4B%40moolenaar.net.