To: vim_dev@googlegroups.com Subject: Patch 8.1.2095 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.1.2095 Problem: Leaking memory when getting item from dict. Solution: Also free the key when not evaluating. Files: src/dict.c *** ../vim-8.1.2094/src/dict.c 2019-08-30 22:07:55.950547106 +0200 --- src/dict.c 2019-09-27 21:19:00.882694429 +0200 *************** *** 822,828 **** goto failret; } item = dictitem_alloc(key); - clear_tv(&tvkey); if (item != NULL) { item->di_tv = tv; --- 822,827 ---- *************** *** 831,836 **** --- 830,836 ---- dictitem_free(item); } } + clear_tv(&tvkey); if (**arg == '}') break; *** ../vim-8.1.2094/src/version.c 2019-09-28 16:29:44.175649771 +0200 --- src/version.c 2019-09-28 17:24:50.906556908 +0200 *************** *** 759,760 **** --- 759,762 ---- { /* Add new patch number below this line */ + /**/ + 2095, /**/ -- There are 2 kinds of people in my world: those who know Unix, Perl, Vim, GNU, Linux, etc, and those who know COBOL. It gets very difficult for me at parties, not knowing which group to socialise with :-) Sitaram Chamarty /// 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 ///