Skip to content

Commit

Permalink
satisfy clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
jbr committed Oct 17, 2020
1 parent afc6fc1 commit a680174
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions src/tls_listener.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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 {
Expand Down

0 comments on commit a680174

Please sign in to comment.