@@ -8,9 +8,9 @@ use deadpool::managed::{Manager, Object, RecycleResult};
8
8
use futures:: io:: { AsyncRead , AsyncWrite } ;
9
9
use futures:: task:: { Context , Poll } ;
10
10
11
- #[ cfg( not ( feature = "h1_client_rustls" ) ) ]
11
+ #[ cfg( feature = "native-tls" ) ]
12
12
use async_native_tls:: TlsStream ;
13
- #[ cfg( feature = "h1_client_rustls " ) ]
13
+ #[ cfg( feature = "rustls " ) ]
14
14
use async_tls:: client:: TlsStream ;
15
15
16
16
use crate :: Error ;
@@ -76,15 +76,15 @@ impl Manager<TlsStream<TcpStream>, Error> for TlsConnection {
76
76
}
77
77
}
78
78
79
- #[ cfg( not ( feature = "h1_client_rustls" ) ) ]
79
+ #[ cfg( feature = "native-tls" ) ]
80
80
async fn add_tls (
81
81
host : & str ,
82
82
stream : TcpStream ,
83
- ) -> Result < async_native_tls :: TlsStream < TcpStream > , async_native_tls:: Error > {
83
+ ) -> Result < TlsStream < TcpStream > , async_native_tls:: Error > {
84
84
async_native_tls:: connect ( host, stream) . await
85
85
}
86
86
87
- #[ cfg( feature = "h1_client_rustls " ) ]
87
+ #[ cfg( feature = "rustls " ) ]
88
88
async fn add_tls ( host : & str , stream : TcpStream ) -> Result < TlsStream < TcpStream > , std:: io:: Error > {
89
89
let connector = async_tls:: TlsConnector :: default ( ) ;
90
90
connector. connect ( host, stream) . await
0 commit comments