[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: RE: Timing out LUA programs
- From: Nick Trout <Nick.Trout@...>
- Date: Tue, 18 Jun 2002 09:57:07 +0100
> I am thinking of "embedding" LUA into my program,but I am concerned
> about users writing "never ending" LUA programs.
> Is there a safe way to shut down the LUA program after an arbitrary
> time interval?
The same way you would in C. You can run for a set time then exit the Lua
state back to C and lua_close() or you could just call exit() in your code
depending on how you wanted to close down.