diff --git a/src/aio/usock_posix.inc b/src/aio/usock_posix.inc index cb90bccc3..e14a9e6a0 100644 --- a/src/aio/usock_posix.inc +++ b/src/aio/usock_posix.inc @@ -815,6 +815,9 @@ static void nn_usock_handler (struct nn_fsm *self, int src, int type, errnum_assert (rc == -ECONNRESET, -rc); goto error; case NN_WORKER_FD_ERR: + /* we ignore the error as we want to read everything we have on the socket before */ + /* socket will be closed and NN_POLLER_IN will be triggered anyway */ + return; error: nn_worker_rm_fd (usock->worker, &usock->wfd); nn_closefd (usock->s);