An exception during server.accept() should not cause the server thread to terminate. Log the exception and continue instead.
Signed-off-by: Jason Kölker <[email protected]> --- ryu/services/protocols/ovsdb/manager.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/ryu/services/protocols/ovsdb/manager.py b/ryu/services/protocols/ovsdb/manager.py index e406c44..16ea08a 100644 --- a/ryu/services/protocols/ovsdb/manager.py +++ b/ryu/services/protocols/ovsdb/manager.py @@ -60,8 +60,13 @@ class OVSDB(app_manager.RyuApp): return True while True: - # TODO(jkoelker) SSL Certificate Fingerprint check - sock, client_address = server.accept() + try: + # TODO(jkoelker) SSL Certificate Fingerprint check + sock, client_address = server.accept() + + except: + self.logger.exception('Error accepting connection') + continue if not check(client_address[0]): sock.shutdown(socket.SHUT_RDWR) -- 2.5.0 ------------------------------------------------------------------------------ Site24x7 APM Insight: Get Deep Visibility into Application Performance APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month Monitor end-to-end web transactions and take corrective actions now Troubleshoot faster and improve end-user experience. Signup Now! http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140 _______________________________________________ Ryu-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/ryu-devel
