Start `connect` for Lua.
Fix a check with pointer indirection.