net.box: fix IO error messages
1. The net.box state machine is supposed to set E_NO_CONNECTION on error, but netbox_transport_connect returns an error returned by coio_connect and coio_read as is. Fix this. 2. netbox_transport_communicate sets the error message to strerror(errno) on coio_read or coio_write error. This works now, because iostream can only be backed by plain sockets, but once we implement encryption, errno won't make any sense. We should use error::errmsg instead. 3. While we are at it, fix luaT_netbox_transport_make_request: it's wrong to pass errmsg directly to box_error_raise - we should use a format specifier (%s). Fixes commit c13b3a31 ("net.box: rewrite state machine (transport) in C").
Loading
Please register or sign in to comment