Skip to main content

sample_from_body

Function sample_from_body 

Source
pub fn sample_from_body(
    scheme: UtcScheme,
    body: &[u8],
    exchange: Exchange,
    max_rtt_us: u64,
) -> Result<UtcSample, TimingError>
Expand description

Sample from the body of an http-xsdate, http-iso or http-ntp response.

ยงErrors

TimingError for an oversized or unreadable body, a scheme that has no body time, or a bad exchange.