diff --git a/actix-tls/src/connect/native_tls.rs b/actix-tls/src/connect/native_tls.rs index 97d027f5..49222228 100644 --- a/actix-tls/src/connect/native_tls.rs +++ b/actix-tls/src/connect/native_tls.rs @@ -11,7 +11,7 @@ use futures_core::future::LocalBoxFuture; use log::trace; use tokio_native_tls::{ native_tls::TlsConnector as NativeTlsConnector, TlsConnector as AsyncNativeTlsConnector, - TlsStream, + TlsStream as AsyncTlsStream, }; use crate::connect::{Connection, Host}; @@ -45,7 +45,7 @@ impl ServiceFactory> for TlsConnector where IO: ActixStream + 'static, { - type Response = Connection>; + type Response = Connection>; type Error = io::Error; type Config = (); type Service = Self; @@ -64,7 +64,7 @@ where R: Host, IO: ActixStream + 'static, { - type Response = Connection>; + type Response = Connection>; type Error = io::Error; type Future = LocalBoxFuture<'static, Result>; diff --git a/actix-tls/src/connect/openssl.rs b/actix-tls/src/connect/openssl.rs index f4d2cf8c..a672d34e 100644 --- a/actix-tls/src/connect/openssl.rs +++ b/actix-tls/src/connect/openssl.rs @@ -15,7 +15,7 @@ use actix_utils::future::{ok, Ready}; use futures_core::ready; use log::trace; use openssl::ssl::SslConnector; -use tokio_openssl::SslStream; +use tokio_openssl::SslStream as AsyncSslStream; use crate::connect::{Connection, Host}; @@ -57,7 +57,7 @@ where R: Host, IO: ActixStream + 'static, { - type Response = Connection>; + type Response = Connection>; type Error = io::Error; type Config = (); type Service = TlsConnectorService; @@ -89,7 +89,7 @@ where R: Host, IO: ActixStream, { - type Response = Connection>; + type Response = Connection>; type Error = io::Error; type Future = ConnectFut; @@ -110,7 +110,7 @@ where .expect("SSL connect configuration was invalid."); ConnectFut { - io: Some(SslStream::new(ssl, io).unwrap()), + io: Some(AsyncSslStream::new(ssl, io).unwrap()), stream: Some(stream), } } @@ -119,7 +119,7 @@ where /// Connect future for OpenSSL service. #[doc(hidden)] pub struct ConnectFut { - io: Option>, + io: Option>, stream: Option>, } @@ -128,7 +128,7 @@ where R: Host, IO: ActixStream, { - type Output = Result>, io::Error>; + type Output = Result>, io::Error>; fn poll(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll { let this = self.get_mut(); diff --git a/actix-tls/src/connect/rustls.rs b/actix-tls/src/connect/rustls.rs index 86d1b5b4..641ddd23 100644 --- a/actix-tls/src/connect/rustls.rs +++ b/actix-tls/src/connect/rustls.rs @@ -17,7 +17,7 @@ use actix_utils::future::{ok, Ready}; use futures_core::ready; use log::trace; use tokio_rustls::rustls::{client::ServerName, OwnedTrustAnchor, RootCertStore}; -use tokio_rustls::{client::TlsStream, rustls::ClientConfig}; +use tokio_rustls::{client::TlsStream as AsyncTlsStream, rustls::ClientConfig}; use tokio_rustls::{Connect as RustlsConnect, TlsConnector as RustlsTlsConnector}; use webpki_roots::TLS_SERVER_ROOTS; @@ -71,7 +71,7 @@ where R: Host, IO: ActixStream + 'static, { - type Response = Connection>; + type Response = Connection>; type Error = io::Error; type Config = (); type Service = TlsConnectorService; @@ -96,7 +96,7 @@ where R: Host, IO: ActixStream, { - type Response = Connection>; + type Response = Connection>; type Error = io::Error; type Future = ConnectFut; @@ -132,7 +132,7 @@ where R: Host, IO: ActixStream, { - type Output = Result>, io::Error>; + type Output = Result>, io::Error>; fn poll(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll { match self.get_mut() {