~kvik/lu9

07fda22831e6aa8a12455d7357f3f03d6376ed67 — kvik 1 year, 14 days ago d64355d
lu9: fix memory leak in REPL
1 files changed, 3 insertions(+), 1 deletions(-)

M lu9.c
M lu9.c => lu9.c +3 -1
@@ 108,7 108,9 @@ runrepl(lua_State *L)
		sysfatal("Binit: %r");
	r = LUA_OK;
	while(fprint(2, "> "), (ln = Brdstr(&bin, '\n', 1)) != nil){
		if(luaL_loadstring(L, ln) != LUA_OK){
		r = luaL_loadstring(L, ln);
		free(ln);
		if(r != LUA_OK){
			luaerror(L);
			continue;
		}