[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Aborting LUA run
- From: Rici Lake <lua@...>
- Date: Wed, 11 Oct 2006 23:28:18 -0500
On 11-Oct-06, at 11:14 PM, jason bright wrote:
I haven't tried, but first thing that comes to mind is to inject an
error when inside the hook function, but thats an ugly solution.
That would be the way to do it. Why is that ugly? pcall is supposed to
catch calls to error() (or lua_error(), inside a C function.)
Starting a thread and killing it is going to leak memory. Throwing an
error() to pcall() is much cleaner.