Commit b79d07b8 authored by Jon Dyte's avatar Jon Dyte Committed by Martin Sustrik

reset socket state when identity message cannot be written to xrep

Signed-off-by: 's avatarJon Dyte <jon@totient.co.uk>
parent 7045a4a2
......@@ -184,9 +184,11 @@ int zmq::xrep_t::xsend (zmq_msg_t *msg_, int flags_)
int rc = zmq_msg_init (&empty);
zmq_assert (rc == 0);
if (!current_out->check_write (&empty)) {
it->second.active = false;
more_out = false;
current_out = NULL;
rc = zmq_msg_close (&empty);
zmq_assert (rc == 0);
it->second.active = false;
errno = EAGAIN;
return -1;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment