From 2a407b8c009329f987b075e69ee8a8d67085906c Mon Sep 17 00:00:00 2001 From: kervala Date: Wed, 19 Oct 2016 10:48:32 +0200 Subject: [PATCH] Fixed: Catch ESocket exceptions when disconnecting and log it --- code/ryzom/client/src/network_connection.cpp | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/code/ryzom/client/src/network_connection.cpp b/code/ryzom/client/src/network_connection.cpp index 5a7e42179..d78fd6199 100644 --- a/code/ryzom/client/src/network_connection.cpp +++ b/code/ryzom/client/src/network_connection.cpp @@ -2756,7 +2756,16 @@ void CNetworkConnection::sendSystemDisconnection() uint32 length = message.length(); if (_Connection.connected()) - _Connection.send (message.buffer(), length); + { + try + { + _Connection.send(message.buffer(), length); + } + catch (const ESocket &e) + { + nlwarning("Socket exception: %s", e.what()); + } + } //sendUDP (&(_Connection), message.buffer(), length); statsSend(length);