Run rustfmt and put back unused `env_logger::init` call
@@ -13,6 +13,8 @@ const SERVER: Token = Token(0);
const DATA: &[u8] = b"Hello world!\n";
fn main() -> io::Result<()> {
+ env_logger::init();
+
// Create a poll instance.
let mut poll = Poll::new()?;
// Create storage for events.
@@ -94,8 +96,7 @@ fn handle_connection_event(
Ok(_) => {
// After we've written something we'll reregister the connection
// to only respond to readable events.
- registry
- .reregister(&connection, event.token(), Interests::READABLE)?
+ registry.reregister(&connection, event.token(), Interests::READABLE)?
}
// Would block "errors" are the OS's way of saying that the
// connection is not actually ready to perform this I/O operation.
