Some Questions about SocketException 10054 thrown from ExitGames.Client.Photon.SocketTcpAsync.
The Exception message:
2019-12-18 14:10:39.761 10511-10543/? E/Unity: SocketTcpAsync.EndReceive SocketException. State: Connected. Server: '47.100.93.146' ErrorCode: 10054 SocketErrorCode: ConnectionReset Message: Connection reset by peer System.Net.Sockets.SocketException (0x80004005): Connection reset by peer
at System.Net.Sockets.Socket.EndReceive (System.IAsyncResult asyncResult) [0x00012] in <3845a180c26b4889bc2d47593a665814>:0
at ExitGames.Client.Photon.SocketTcpAsync.ReceiveAsync (System.IAsyncResult ar) [0x00023] in <e2387f9dc4784e52ba991612d3ef9d57>:0
We cannot see relevant codes about this exception ,but it may have some affects to our application, I have two questions as follows:
1. Is ExitGames.Client.Photon.SocketTcpAsync.ReceiveAsync executed in the Unity main thread?
2.Is this function included in a try catch sentence?
Thanks,
Harlan.
Comments
-
Hi @harlan,
- No. Since it's async. the socket uses a separate thread.
- Yes. That's why you see that exception being logged explicitly inside a try catch.
The client should disconnect automatically after this exception with
DisconnectCause.Exception
.0