1
0
mirror of https://github.com/fafhrd91/actix-net synced 2025-06-28 05:10:36 +02:00

refactor Resolver service

This commit is contained in:
Nikolay Kim
2018-10-29 20:29:47 -07:00
parent 67961f8a36
commit dc19a9f862
14 changed files with 107 additions and 134 deletions

View File

@ -80,8 +80,7 @@ fn main() {
future::ok(())
})
},
)
.unwrap()
).unwrap()
.start();
sys.run();

View File

@ -24,7 +24,8 @@ struct ServiceState {
}
fn service<T: AsyncRead + AsyncWrite>(
st: &mut ServiceState, _: T,
st: &mut ServiceState,
_: T,
) -> impl Future<Item = (), Error = ()> {
let num = st.num.fetch_add(1, Ordering::Relaxed);
println!("got ssl connection {:?}", num);
@ -60,8 +61,7 @@ fn main() {
println!("got ssl connection {:?}", num);
future::ok(())
})
})
.unwrap()
}).unwrap()
.start();
sys.run();