To: vim_dev@googlegroups.com Subject: Patch 8.2.1975 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.2.1975 Problem: Win32: memory leak when encoding conversion fails. Solution: Free the allocated memory. (Ken Takata, closes #7277) Files: src/os_win32.c *** ../vim-8.2.1974/src/os_win32.c 2020-09-03 19:25:08.026072635 +0200 --- src/os_win32.c 2020-11-10 22:02:27.171566842 +0100 *************** *** 3532,3538 **** --- 3532,3541 ---- wn = enc_to_utf16(fname, NULL); if (wn == NULL) + { + vim_free(p); return NULL; + } // Try to retrieve the entire security descriptor. err = GetNamedSecurityInfoW( *** ../vim-8.2.1974/src/version.c 2020-11-10 20:57:51.082004649 +0100 --- src/version.c 2020-11-10 22:03:21.171392118 +0100 *************** *** 752,753 **** --- 752,755 ---- { /* Add new patch number below this line */ + /**/ + 1975, /**/ -- hundred-and-one symptoms of being an internet addict: 232. You start conversations with, "Have you gotten a fiber connection?" /// Bram Moolenaar -- Bram@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 ///