On Fri, Jan 13, 2012 at 2:35 AM, Luis Carvalho <[email protected]> wrote: > Hi Nakadaira-san, > >> if_lua_5.2_udata.diff causes crash. >> >> :let x = {"n": 123} >> :lua x = vim.eval("x") >> :unlet x >> >> ... do something to waste memory >> :for i in range(999999) | let z = {"n": 999} | endfor >> >> :lua print(x.n) <- Vim's x is already freed >> crash... > > Thanks for the report! I'm attaching a patch that should fix it; can you > please try it? > > I had to change eval.c and proto/if_lua.pro to notify Lua whenever a list and > dict are freed: lists and dicts are now not different from buffer and window > objects. I also had to add validity checks for all functions on these objects > -- I think Muraoka also had similar checks in his previous patch and I forgot > to add them.
It works. Thank you. -- Yukihiro Nakadaira - [email protected] -- 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
