summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Shepelev <temotor@gmail.com>2015-05-15 03:56:04 +0300
committerSergey Shepelev <temotor@gmail.com>2015-05-15 04:13:09 +0300
commited0655333007fe97624b745e92deb407d192022c (patch)
tree0f9a1b132a953c9a56f10935dede23befcb8d98c
parentdc10af4702115ee92803e432c18ef3a4350e0993 (diff)
downloadeventlet-gh-192.tar.gz
greenio: send() was running empty loop on ENOTCONN; Thanks to Seyeong Kimgh-192
https://github.com/eventlet/eventlet/issues/192
-rw-r--r--AUTHORS1
-rw-r--r--eventlet/greenio/base.py3
2 files changed, 3 insertions, 1 deletions
diff --git a/AUTHORS b/AUTHORS
index e0ab0e2..c57f010 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -119,3 +119,4 @@ Thanks To
* Sean Dague, wsgi: Provide python logging compatibility
* Tim Simmons, Use _socket_nodns and select in dnspython support
* Antonio Cuni, fix fd double close on PyPy
+* Seyeong Kim
diff --git a/eventlet/greenio/base.py b/eventlet/greenio/base.py
index 8da51ca..1e43176 100644
--- a/eventlet/greenio/base.py
+++ b/eventlet/greenio/base.py
@@ -358,7 +358,8 @@ class GreenSocket(object):
try:
total_sent += fd.send(data[total_sent:], flags)
except socket.error as e:
- if get_errno(e) not in SOCKET_BLOCKING:
+ eno = get_errno(e)
+ if eno == errno.ENOTCONN or eno not in SOCKET_BLOCKING:
raise
if total_sent == len_data: