From 038fd9037a10ee32e671a29c93f5647c23fa780d Mon Sep 17 00:00:00 2001 From: Milo Turner Date: Wed, 11 Mar 2020 13:51:29 -0400 Subject: [PATCH] ooop --- hptp/src/msg.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/hptp/src/msg.rs b/hptp/src/msg.rs index 1946b09..cf33e3b 100644 --- a/hptp/src/msg.rs +++ b/hptp/src/msg.rs @@ -21,9 +21,10 @@ pub enum DownMsg { pub struct DesError; pub trait SerDes: Sized { - // For both methods: `buf.len()` must be >= `MAX_SERIALIZED_SIZE` - + // `buf.len()` must be <= `MAX_TOTAL_PACKET_SIZE` fn des(buf: &[u8]) -> Result; + + // `buf.len()` must be >= `MAX_TOTAL_PACKET_SIZE` fn ser_to(&self, buf: &mut [u8]) -> usize; }