diff --git a/src/connection.rs b/src/connection.rs index 90f54c5..5a5c0ba 100644 --- a/src/connection.rs +++ b/src/connection.rs @@ -104,7 +104,7 @@ impl Drop for Connection { match self.end() { Ok(_) => (), Err(Error::IO(err)) if err.kind() == std::io::ErrorKind::NotConnected => (), - Err(e) => panic!("Error closing connection: {:?}", e), + Err(e) => Err(e).unwrap(), } } }