lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


> I don't want to seems stubborn, but some days ago I asked a question that
> went unnoticed, so I ask again :-)

I did answer you!

> > The stand-alone Lua executable has the -c option, to "call lua_close
> > after running all arguments". For me, I have to put this option
> > systematically. So why is this an option? In which cases it can be
> > unnecessary, or even troublesome, to use it?
> 
> In several "common" platforms (such as most Unixes and Windows) you
> get nothing by closing the state, as all resorces (memory and file
> descriptors) are automatically released by the system when the program
> ends.
> 
> On the other hand, closing a large state takes some time, as Lua has to
> release all memory it was using.
> 
> -- Roberto