Commit fc17bd41 authored by Martin Sustrik's avatar Martin Sustrik

ENOTCONN on recv() on TCP socket is treated decently (issue 254)

Signed-off-by: 's avatarMartin Sustrik <sustrik@250bpm.com>
parent daac9ac5
...@@ -360,7 +360,7 @@ int zmq::stream_engine_t::read (void *data_, size_t size_) ...@@ -360,7 +360,7 @@ int zmq::stream_engine_t::read (void *data_, size_t size_)
// Signalise peer failure. // Signalise peer failure.
if (nbytes == -1 && (errno == ECONNRESET || errno == ECONNREFUSED || if (nbytes == -1 && (errno == ECONNRESET || errno == ECONNREFUSED ||
errno == ETIMEDOUT || errno == EHOSTUNREACH)) errno == ETIMEDOUT || errno == EHOSTUNREACH || errno == ENOTCONN))
return -1; return -1;
errno_assert (nbytes != -1); errno_assert (nbytes != -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