Fixed memory leaks in the Lua sandbox when creating proxies and when creating coroutines. Closes #479.