satisfy clippy

This commit is contained in:
Jacob Rothstein 2020-10-16 18:44:02 -07:00
parent afc6fc15ff
commit a68017473e
No known key found for this signature in database
GPG Key ID: C38BA18C6CFE15A5
1 changed files with 5 additions and 6 deletions

View File

@ -166,12 +166,11 @@ impl<State: Clone + Send + Sync + 'static> Listener<State> for TlsListener {
}
fn is_transient_error(e: &io::Error) -> bool {
match e.kind() {
io::ErrorKind::ConnectionRefused
| io::ErrorKind::ConnectionAborted
| io::ErrorKind::ConnectionReset => true,
_ => false,
}
use io::ErrorKind::*;
matches!(
e.kind(),
ConnectionRefused | ConnectionAborted | ConnectionReset
)
}
impl Display for TlsListener {