mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
Small connection error handling improvement
This commit is contained in:
parent
ede05c47b0
commit
06ea29bd4c
@ -1,5 +1,5 @@
|
||||
use client::{error::Error as ClientError, Client};
|
||||
use common::comp;
|
||||
use common::{comp, net::PostError};
|
||||
use crossbeam::channel::{unbounded, Receiver, TryRecvError};
|
||||
use std::sync::atomic::{AtomicBool, Ordering};
|
||||
use std::sync::Arc;
|
||||
@ -87,6 +87,10 @@ impl ClientInit {
|
||||
}
|
||||
Err(err) => {
|
||||
match err {
|
||||
ClientError::Network(PostError::Bincode(_)) => {
|
||||
last_err = Some(Error::ConnectionFailed(err));
|
||||
break 'tries;
|
||||
}
|
||||
// Assume the connection failed and try again soon
|
||||
ClientError::Network(_) => {}
|
||||
ClientError::TooManyPlayers => {
|
||||
|
Loading…
Reference in New Issue
Block a user