marceldev89 / BattleNET

BattlEye Protocol Library and Client
GNU Lesser General Public License v3.0
76 stars 44 forks source link

EBattlEyeDisconnectionType.ConnectionFailed gets thrown when connection is lost #13

Closed DomiStyle closed 11 years ago

DomiStyle commented 11 years ago

It seems that with the new update BattleNET will throw ConnectionFailed if the server goes down while BattleNET is connected. It should be ConnectionLost or SocketException though. This may lead to misleading error messages since ConnectionFailed should only be thrown when BattleNET is trying to connect. Using the latest version of BattleNET, tested with DaRT.

marceldev89 commented 11 years ago

Hmm, the only place where ConnectionFailed is fired is in BattlEyeClient.Connect() and this should only happen if an exception is catched.

marceldev89 commented 11 years ago

Actually, it's doing the right thing kinda. Connection fails because it fails to receive anything. Except for the fact that it stops retrying after that.

Connecting to 31.25.103.105:2302...
Connected!
RCon admin #0 (217.120.128.173:64770) logged in
Disconnected! (Connection timeout)
Connecting to 31.25.103.105:2302...
Connection failed!
marceldev89 commented 11 years ago

Reverting to old behavior.