diff options
-rw-r--r-- | src/or/buffers.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/or/buffers.c b/src/or/buffers.c index 456b1e1b7b..f5dd19135b 100644 --- a/src/or/buffers.c +++ b/src/or/buffers.c @@ -402,6 +402,10 @@ read_to_buf_impl(int s, size_t at_most, buf_t *buf, if (read_result < 0) { int e = tor_socket_errno(s); if (!ERRNO_IS_EAGAIN(e)) { /* it's a real error */ +#ifdef MS_WINDOWS + if (e == WSAENOBUFS) + log_warn(LD_NET,"recv() failed: WSAENOBUFS. Not enough ram?"); +#endif return -1; } return 0; /* would block. */ @@ -572,6 +576,10 @@ flush_buf_impl(int s, buf_t *buf, size_t sz, size_t *buf_flushlen) if (write_result < 0) { int e = tor_socket_errno(s); if (!ERRNO_IS_EAGAIN(e)) { /* it's a real error */ +#ifdef MS_WINDOWS + if (e == WSAENOBUFS) + log_warn(LD_NET,"write() failed: WSAENOBUFS. Not enough ram?"); +#endif return -1; } log_debug(LD_NET,"write() would block, returning."); |