summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Sustrik <sustrik@250bpm.com>2011-11-22 14:48:35 +0100
committerMartin Sustrik <sustrik@250bpm.com>2011-11-22 14:48:35 +0100
commitfc17bd4117c19b027790951ac1df1a141bce9d82 (patch)
treed62dc64910b616e1ac6f57756ff5789c62b701cb
parentdaac9ac5b2f864f61615a4e93caf49e6ea187cda (diff)
ENOTCONN on recv() on TCP socket is treated decently (issue 254)
Signed-off-by: Martin Sustrik <sustrik@250bpm.com>
-rw-r--r--src/stream_engine.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/stream_engine.cpp b/src/stream_engine.cpp
index 11ec264..ab6329a 100644
--- a/src/stream_engine.cpp
+++ b/src/stream_engine.cpp
@@ -360,7 +360,7 @@ int zmq::stream_engine_t::read (void *data_, size_t size_)
// Signalise peer failure.
if (nbytes == -1 && (errno == ECONNRESET || errno == ECONNREFUSED ||
- errno == ETIMEDOUT || errno == EHOSTUNREACH))
+ errno == ETIMEDOUT || errno == EHOSTUNREACH || errno == ENOTCONN))
return -1;
errno_assert (nbytes != -1);