From e0b5d6f5d669b1c74208a3d91c8094dc33960861 Mon Sep 17 00:00:00 2001 From: Taylor Baldwin Date: Mon, 6 Jan 2025 10:01:58 -0500 Subject: [PATCH] changes per comments --- dynamic-proxy/src/server.rs | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/dynamic-proxy/src/server.rs b/dynamic-proxy/src/server.rs index 76226e919..0e8d614dc 100644 --- a/dynamic-proxy/src/server.rs +++ b/dynamic-proxy/src/server.rs @@ -31,12 +31,7 @@ pub struct SimpleHttpServer { graceful_shutdown: Option, } -#[must_use] // Otherwise, the tasks we started would be stopped as soon as the graceful shutdown is initiated. -async fn listen_loop( - listener: TcpListener, - service: S, - graceful_shutdown: GracefulShutdown, -) -> () +async fn listen_loop(listener: TcpListener, service: S, graceful_shutdown: GracefulShutdown) where S: Service, Response = Response> + Clone + Send + 'static, S::Future: Send + 'static, @@ -73,14 +68,12 @@ where } } -#[must_use] // Otherwise, the tasks we started would be stopped as soon as the graceful shutdown is initiated. async fn listen_loop_tls( listener: TcpListener, service: S, resolver: Arc, graceful_shutdown: GracefulShutdown, -) -> () -where +) where S: Service, Response = Response> + Clone + Send + 'static, S::Future: Send + 'static, S::Error: Into>,