diff --git a/src/main.rs b/src/main.rs index 3e68062..5cad5a6 100644 --- a/src/main.rs +++ b/src/main.rs @@ -84,16 +84,12 @@ async fn main() -> Result<()> { let service = app.into_make_service(); - let addr4 = SocketAddr::from((Ipv4Addr::UNSPECIFIED, opts.port)); let addr6 = SocketAddr::from((Ipv6Addr::UNSPECIFIED, opts.port)); - println!("Listening on {} and {}...", addr4, addr6); + println!("Listening on {}...", addr6); - let server4 = Server::bind(&addr4).serve(service.clone()); let server6 = Server::bind(&addr6).serve(service); - let (result4, result6) = join!(server4, server6); - result4?; - result6?; + server6.await?; Ok(()) }