From f61bb5f9385a9fd177ea5cceefdec7af2410e756 Mon Sep 17 00:00:00 2001 From: "Victor J. Orlikowski" Date: Tue, 19 Apr 2016 19:28:03 -0400 Subject: [PATCH] Eventlet throws a subclass of IOError when an SSL read timeout occurs. Ensure that the read loop continues in this case. Signed-off-by: Victor J. Orlikowski Tested-by: Andy Hill Signed-off-by: FUJITA Tomonori --- ryu/controller/controller.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ryu/controller/controller.py b/ryu/controller/controller.py index 08304d21..1ae72876 100644 --- a/ryu/controller/controller.py +++ b/ryu/controller/controller.py @@ -194,6 +194,10 @@ class Datapath(ofproto_protocol.ProtocolDesc): ret = self.socket.recv(required_len) except SocketTimeout: continue + except ssl.SSLError: + # eventlet throws SSLError (which is a subclass of IOError) + # on SSL socket read timeout; re-try the loop in this case. + continue except (EOFError, IOError): break