protocols/ovsdb: Handle disconnects gracefully
If the client closes the connection during setup, the socket's FD is closed out automatically, ignore the errors while forcably shuting down the socket. Signed-off-by: Jason Kölker <jason@koelker.net> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
This commit is contained in:
committed by
FUJITA Tomonori
parent
5d04752421
commit
df065f5bb1
@@ -92,7 +92,11 @@ class OVSDB(app_manager.RyuApp):
|
||||
self.send_event_to_observers(ev)
|
||||
|
||||
else:
|
||||
sock.shutdown(socket.SHUT_RDWR)
|
||||
try:
|
||||
sock.shutdown(socket.SHUT_RDWR)
|
||||
except:
|
||||
pass
|
||||
|
||||
sock.close()
|
||||
|
||||
def start(self):
|
||||
|
||||
Reference in New Issue
Block a user