diff --git a/statime/src/datastructures/messages/mod.rs b/statime/src/datastructures/messages/mod.rs index e4c3ac3e3..90f110b1b 100644 --- a/statime/src/datastructures/messages/mod.rs +++ b/statime/src/datastructures/messages/mod.rs @@ -310,7 +310,6 @@ impl<'a> Message<'a> { } impl Message<'_> { - #[allow(unused)] pub(crate) fn verify_signed(&self, provider: &impl SecurityAssociationProvider) -> bool { log::trace!("Validation message"); let mut tlv_offset = 0; diff --git a/statime/src/port/state/master.rs b/statime/src/port/state/master.rs index 9be5928f9..58aa86e5f 100644 --- a/statime/src/port/state/master.rs +++ b/statime/src/port/state/master.rs @@ -182,19 +182,16 @@ impl MasterState { } } - let packet_length = - match Message::announce(global, port_identity, self.announce_seq_ids.generate()) - .serialize(buffer) - { - Ok(length) => length, - Err(error) => { - log::error!( - "Statime bug: Could not serialize announce message {:?}", - error - ); - return actions![]; - } - }; + let packet_length = match message.serialize(buffer) { + Ok(length) => length, + Err(error) => { + log::error!( + "Statime bug: Could not serialize announce message {:?}", + error + ); + return actions![]; + } + }; actions![ PortAction::ResetAnnounceTimer {