Yukihiro Nakadaira wrote:
> Kana Natsuno wrote: > > On Mon, 12 Oct 2009 05:03:27 +0900, Bram Moolenaar <[email protected]> > > wrote: > >> Can you somehow simplify the way to reproduce this and send me the Vim > >> script for this? > > > > Sorry, I tried to simplify before reporting but failed. Because the > > problem I encountered seems to depend on the number/order of operations, > > and the problem doesn't occur even if I delete a key/value pair > > expression from dictionary literal which seems not to be related to > > executing scripts. > > > > Anyway, I'll try to simplify again. > > Perhaps your problem is ... > > In eval.c, all "s:" dictionary is stored in one array (ga_scripts). > When new script file is sourced, the array is re-allocated for new "s:" > dictionary. Then "s:" dictionary, previously assigned to other variable > (e.g. :let g:foo = s:), will become an invalid pointer. > > > Script to reproduce: (might not crash 100%) > > let script_vars = [] > for src in range(10) > call writefile(['call add(script_vars, s:)'], src) > source `=src` > " allocate memory to ensure crash. > call repeat(' ', 1000) > endfor > echo script_vars Very good point. Thanks for finding this problem. I'll think about a solution. Unless someone beats me to it. -- This is the polymorph virus! Follow these instructions carefully: 1. Send this message to everybody you know. 2. Format your harddisk. Thank you for your cooperation in spreading the most powerful virus ever! /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\ /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ \\\ download, build and distribute -- http://www.A-A-P.org /// \\\ help me help AIDS victims -- http://ICCF-Holland.org /// --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_dev" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~---
