Promote the Warning to an Error, because thats how it was before. Move it above the disconnect, in case Disconnect throws. (#756)

This commit is contained in:
rodolphito 2019-04-07 09:41:01 -07:00 committed by vis2k
parent ecccb88be5
commit 765c87e80c

View File

@ -257,8 +257,8 @@ public virtual void TransportReceive(byte[] buffer)
} }
catch (Exception exception) catch (Exception exception)
{ {
Debug.LogError("Closed connection: " + connectionId + ". This can happen if the other side accidentally (or an attacker intentionally) sent invalid data. Reason: " + exception);
Disconnect(); Disconnect();
Debug.LogWarning("Closed connection: " + connectionId + ". This can happen if the other side accidentally (or an attacker intentionally) sent invalid data. Reason: " + exception);
} }
} }