1
0
mirror of https://github.com/actix/actix-extras.git synced 2024-11-28 01:32:57 +01:00

do not stop accept thread on error

This commit is contained in:
Nikolay Kim 2018-02-15 22:02:03 -08:00
parent 080bb3e5ae
commit 8607c51bcf

View File

@ -628,11 +628,11 @@ fn start_accept_thread(sock: net::TcpListener, addr: net::SocketAddr, backlog: i
.expect("worker thread died");
next = (next + 1) % workers.len();
},
Err(err) => if err.kind() == io::ErrorKind::WouldBlock {
break
} else {
Err(err) => {
if err.kind() != io::ErrorKind::WouldBlock {
error!("Error accepting connection: {:?}", err);
return
}
break
}
}
}