fix bogus memory management — we cannot return memory we probably just freed, but must point our caller to the copy Lua made