From 1a490e25c321bdd173d47ed7a7a704039746fb29 Mon Sep 17 00:00:00 2001 From: Stacey Ell Date: Fri, 26 Jun 2015 09:27:27 -0600 Subject: [PATCH] fix(client): use Ssl instance in creation of SslStream This fix brings SNI into working order --- src/net.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/net.rs b/src/net.rs index 1ed7486b..34733408 100644 --- a/src/net.rs +++ b/src/net.rs @@ -444,7 +444,7 @@ mod openssl { //} let ssl = try!(Ssl::new(&self.context)); try!(ssl.set_hostname(host)); - SslStream::new(&self.context, stream).map_err(From::from) + SslStream::new_from(ssl, stream).map_err(From::from) } fn wrap_server(&self, stream: HttpStream) -> ::Result {