1
0
mirror of https://github.com/fafhrd91/actix-net synced 2025-06-30 01:24:59 +02:00

service trait takes shared self reference (#247)

This commit is contained in:
fakeshadow
2021-01-22 19:06:22 -08:00
committed by GitHub
parent 874e5f2e50
commit 636cef8868
27 changed files with 225 additions and 219 deletions

View File

@ -84,7 +84,7 @@ where
actix_service::always_ready!();
fn call(&mut self, stream: Connection<T, U>) -> Self::Future {
fn call(&self, stream: Connection<T, U>) -> Self::Future {
trace!("SSL Handshake start for: {:?}", stream.host());
let (io, stream) = stream.replace(());
let host = stream.host();
@ -202,7 +202,7 @@ impl<T: Address + 'static> Service<Connect<T>> for OpensslConnectService {
actix_service::always_ready!();
fn call(&mut self, req: Connect<T>) -> Self::Future {
fn call(&self, req: Connect<T>) -> Self::Future {
OpensslConnectServiceResponse {
fut1: Some(self.tcp.call(req)),
fut2: None,

View File

@ -84,7 +84,7 @@ where
actix_service::always_ready!();
fn call(&mut self, stream: Connection<T, U>) -> Self::Future {
fn call(&self, stream: Connection<T, U>) -> Self::Future {
trace!("SSL Handshake start for: {:?}", stream.host());
let (io, stream) = stream.replace(());
let host = DNSNameRef::try_from_ascii_str(stream.host())