[Tarantool-patches] [PATCH 18/20] net.box: rewrite iproto handlers in C

Vladimir Davydov vdavydov at tarantool.org
Thu Aug 5 14:54:34 MSK 2021


On Wed, Aug 04, 2021 at 01:08:25AM +0200, Vladislav Shpilevoy wrote:
> > +static int
> > +netbox_iproto_auth(struct lua_State *L)
> > +{
> > +	size_t user_len;
> > +	const char *user = lua_tolstring(L, 1, &user_len);
> > +	size_t password_len;
> > +	const char *password = lua_tolstring(L, 2, &password_len);
> > +	size_t salt_len;
> > +	const char *salt = lua_tolstring(L, 3, &salt_len);
> > +	if (salt_len < SCRAMBLE_SIZE)
> > +		return luaL_error(L, "Invalid salt");
> > +	struct netbox_registry *registry = luaT_check_netbox_registry(L, 4);
> > +	int fd = lua_tointeger(L, 5);
> > +	struct ibuf *send_buf = (struct ibuf *) lua_topointer(L, 6);
> > +	struct ibuf *recv_buf = (struct ibuf *) lua_topointer(L, 7);
> > +	double timeout = (!lua_isnoneornil(L, 8) ?
> > +			  lua_tonumber(L, 8) : TIMEOUT_INFINITY);
> 
> Timeout is never passed, it is always TIMEOUT_INFINITY. The same in
> netbox_iproto_schema and netbox_iproto_loop.

Fixed in a separate patch:

https://lists.tarantool.org/pipermail/tarantool-patches/2021-August/025208.html


More information about the Tarantool-patches mailing list