[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Closing the Lua state before exiting
- From: Daurnimator <quae@...>
- Date: Mon, 9 Feb 2015 00:59:11 -0500
On 9 February 2015 at 00:53, Dirk Laurie <dirk.laurie@gmail.com> wrote:
> The manual for `os.exit` states:
>
> If the optional second argument close is true, closes the Lua state before
> exiting.
>
> 1. Why would one want to do this?
To ensure all resources are cleaned up correctly.
This may mean cleaning closing connections to servers, etc.
> 2. Why would one not want to to do this every time?
If you know there are no resources to be cleaned up and want to exit fast.