Yes, we use luaL_Buffer. Sorry, I didn't describe the context clearly a moment ago. We use luaL_buffer and there is some stack modification, which not follow the lua string buffer documentation.
Thanks for your clue. I'll verify it.
Are you using string buffers (luaL_Buffer)? They use to-be-closed
variables. Maybe you are removing a buffer from the stack without
properly finalizing it first.
-- Roberto