Skip to content

Commit

Permalink
Merge pull request #41 from sfackler/fix-client-legacy
Browse files Browse the repository at this point in the history
Fix build
  • Loading branch information
sfackler authored Nov 21, 2023
2 parents a7399c9 + a6ed62c commit 4265f58
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
3 changes: 2 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
name = "hyper-openssl"
version = "0.10.0"
authors = ["Steven Fackler <[email protected]>"]
edition = "2018"
edition = "2021"
description = "Hyper TLS support via OpenSSL"
license = "MIT/Apache-2.0"
repository = "https://github.com/sfackler/hyper-openssl"
Expand All @@ -27,6 +27,7 @@ client-legacy = [
"hyper-util?/client-legacy",
]

tokio = ["hyper-util?/tokio"]

[dependencies]
http = { version = "1.0.0", optional = true }
Expand Down
5 changes: 4 additions & 1 deletion src/client/legacy.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ use crate::SslStream;
use http::uri::Scheme;
use hyper::rt::{Read, ReadBufCursor, Write};
use hyper::Uri;
use hyper_util::client::legacy::connect::{Connected, Connection, HttpConnector};
#[cfg(feature = "tokio")]
use hyper_util::client::legacy::connect::HttpConnector;
use hyper_util::client::legacy::connect::{Connected, Connection};
use once_cell::sync::OnceCell;
use openssl::error::ErrorStack;
use openssl::ex_data::Index;
Expand Down Expand Up @@ -115,6 +117,7 @@ pub struct HttpsConnector<T> {
inner: Inner,
}

#[cfg(feature = "tokio")]
impl HttpsConnector<HttpConnector> {
/// Creates a new `HttpsConnector` using default settings.
///
Expand Down

0 comments on commit 4265f58

Please sign in to comment.