From 40dae63b65ace6aac47374749b686d57d1a076d1 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Fri, 16 Jun 2023 12:54:59 +0100 Subject: [PATCH] arti-client hs: connect_to_onion_services: default to true This should be enabled by default. There's still no setter for not, nor is it honoured - those are separate TODOs. --- crates/arti-client/src/client.rs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/crates/arti-client/src/client.rs b/crates/arti-client/src/client.rs index 1a26172a9..1a3bd1e9d 100644 --- a/crates/arti-client/src/client.rs +++ b/crates/arti-client/src/client.rs @@ -198,7 +198,9 @@ pub enum DormantMode { } /// Preferences for how to route a stream over the Tor network. -#[derive(Debug, Default, Clone)] +#[derive(Debug, Clone)] +#[derive(Educe)] +#[educe(Default)] pub struct StreamPrefs { /// What kind of IPv6/IPv4 we'd prefer, and how strongly. ip_ver_pref: IpVersionPreference, @@ -209,7 +211,8 @@ pub struct StreamPrefs { /// Whether to try to make connections to onion services. #[cfg(feature = "onion-service-client")] #[allow(dead_code)] - connect_to_onion_services: bool, // TODO hs: this should default to "true". + #[educe(Default(true))] + connect_to_onion_services: bool, } /// Record of how we are isolating connections