File tree Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Original file line number Diff line number Diff line change 1- use async_std:: net:: { TcpListener , TcpStream } ;
2- use async_std:: task;
31use async_std:: io;
4- use async_std:: sync :: channel ;
2+ use async_std:: net :: { TcpListener , TcpStream } ;
53use async_std:: prelude:: * ;
4+ use async_std:: sync:: channel;
5+ use async_std:: task;
66use async_tls:: { TlsAcceptor , TlsConnector } ;
77use lazy_static:: lazy_static;
88use rustls:: internal:: pemfile:: { certs, rsa_private_keys} ;
99use rustls:: { ClientConfig , ServerConfig } ;
10- use std:: net:: SocketAddr ;
1110use std:: io:: { BufReader , Cursor } ;
11+ use std:: net:: SocketAddr ;
1212use std:: sync:: Arc ;
1313
1414const CERT : & str = include_str ! ( "end.cert" ) ;
@@ -49,9 +49,7 @@ lazy_static! {
4949 Ok ( ( ) ) as io:: Result <( ) >
5050 } ) ;
5151
52- let addr = task:: block_on( async move {
53- recv. recv( ) . await . unwrap( )
54- } ) ;
52+ let addr = task:: block_on( async move { recv. recv( ) . await . unwrap( ) } ) ;
5553 ( addr, "localhost" , CHAIN )
5654 } ;
5755}
You can’t perform that action at this time.
0 commit comments