diff options
| author | tv <tv@krebsco.de> | 2026-10-31 06:51:17 +0100 |
|---|---|---|
| committer | tv <tv@krebsco.de> | 2026-10-31 06:51:17 +0100 |
| commit | 4855ff63536430b1cd26734a0eeeaf0c25df553e (patch) | |
| tree | 0c7d636fc007301b37a28ee3b48bfbf2283b9342 /src/transport/mod.rs | |
| parent | a216c65c48f6b662ce083873d6e344fbee1c556b (diff) | |
calculate peer clock drift
Diffstat (limited to 'src/transport/mod.rs')
| -rw-r--r-- | src/transport/mod.rs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/transport/mod.rs b/src/transport/mod.rs index 9a82cbe..1ce4cd1 100644 --- a/src/transport/mod.rs +++ b/src/transport/mod.rs @@ -880,6 +880,13 @@ pub(crate) trait Transport: Send + Sync { None } + /// How far `peer`'s clock is ahead of ours, as its PONGs say (`paths::ClockOffset`): + /// the narrowest bound of its paths. By default unknown. + fn clock_offset(&self, peer: &str) -> Option<paths::ClockOffset> { + let _ = peer; + None + } + /// Whether the transport answers PINGs with PONGs itself (the paths layer, /// `transport::paths`); if not (a bare transport, in tests), the node does. By /// default not. |
