Skip to main content

read_frame

Function read_frame 

Source
pub fn read_frame<R>(r: &mut R) -> Result<Option<Vec<u8>>, Error>
where R: Read,
Expand description

Read one length-prefixed frame. Returns Ok(None) on clean EOF before the length prefix (orderly shutdown). A declared length over MAX_FRAME is rejected before allocation.