Loading crates/tor-dirmgr/src/config.rs +10 −1 Original line number Diff line number Diff line Loading @@ -267,7 +267,7 @@ impl DirMgrConfig { /// `self` are replaced with those from `new_config`. /// /// Any fields which aren't allowed to change at runtime are copied from self. pub fn update_config(&self, new_config: &DirMgrConfig) -> DirMgrConfig { pub(crate) fn update_from_config(&self, new_config: &DirMgrConfig) -> DirMgrConfig { DirMgrConfig { cache_path: self.cache_path.clone(), network_config: NetworkConfig { Loading @@ -278,6 +278,15 @@ impl DirMgrConfig { override_net_params: new_config.override_net_params.clone(), } } /// Construct a new configuration object where all replaceable fields in /// `self` are replaced with those from `new_config`. /// /// Any fields which aren't allowed to change at runtime are copied from self. #[cfg(feature = "experimental-api")] pub fn update_config(&self, new_config: &DirMgrConfig) -> DirMgrConfig { self.update_from_config(new_config) } } impl DownloadScheduleConfig { Loading crates/tor-dirmgr/src/lib.rs +1 −1 Original line number Diff line number Diff line Loading @@ -620,7 +620,7 @@ impl<R: Runtime> DirMgr<R> { let params_changed = new_config.override_net_params() != config.override_net_params(); self.config .map_and_replace(|cfg| cfg.update_config(new_config)); .map_and_replace(|cfg| cfg.update_from_config(new_config)); if params_changed { let _ignore_err = self.netdir.mutate(|netdir| { Loading doc/semver_status.md +9 −0 Original line number Diff line number Diff line Loading @@ -35,4 +35,13 @@ arti-client: api-break (experimental only): changed circmgr() and dirmgr() to return &Arc, not Arc. tor-dirmgr: new-api: DirMgrConfig object now has accessors. tor-netdoc: new-api (experimental only): Can modify the set of relays in an unverified consensus. Loading
crates/tor-dirmgr/src/config.rs +10 −1 Original line number Diff line number Diff line Loading @@ -267,7 +267,7 @@ impl DirMgrConfig { /// `self` are replaced with those from `new_config`. /// /// Any fields which aren't allowed to change at runtime are copied from self. pub fn update_config(&self, new_config: &DirMgrConfig) -> DirMgrConfig { pub(crate) fn update_from_config(&self, new_config: &DirMgrConfig) -> DirMgrConfig { DirMgrConfig { cache_path: self.cache_path.clone(), network_config: NetworkConfig { Loading @@ -278,6 +278,15 @@ impl DirMgrConfig { override_net_params: new_config.override_net_params.clone(), } } /// Construct a new configuration object where all replaceable fields in /// `self` are replaced with those from `new_config`. /// /// Any fields which aren't allowed to change at runtime are copied from self. #[cfg(feature = "experimental-api")] pub fn update_config(&self, new_config: &DirMgrConfig) -> DirMgrConfig { self.update_from_config(new_config) } } impl DownloadScheduleConfig { Loading
crates/tor-dirmgr/src/lib.rs +1 −1 Original line number Diff line number Diff line Loading @@ -620,7 +620,7 @@ impl<R: Runtime> DirMgr<R> { let params_changed = new_config.override_net_params() != config.override_net_params(); self.config .map_and_replace(|cfg| cfg.update_config(new_config)); .map_and_replace(|cfg| cfg.update_from_config(new_config)); if params_changed { let _ignore_err = self.netdir.mutate(|netdir| { Loading
doc/semver_status.md +9 −0 Original line number Diff line number Diff line Loading @@ -35,4 +35,13 @@ arti-client: api-break (experimental only): changed circmgr() and dirmgr() to return &Arc, not Arc. tor-dirmgr: new-api: DirMgrConfig object now has accessors. tor-netdoc: new-api (experimental only): Can modify the set of relays in an unverified consensus.