This commit is contained in:
rich-murphey 2021-02-12 04:10:46 -06:00 committed by Ryan Leckey
parent 45a4f14f8c
commit 1fe689771c

View File

@ -54,7 +54,7 @@ macro_rules! read_packet {
read_packet!($(@$blocking)? @stream $self, 0, 5);
// peek at the messaage type and payload size
let r#type = MessageType::try_from(*$self.stream.get(0, 1)s@)?;
let r#type = MessageType::try_from(*$self.stream.get(0, 1))?;
let size = (u32::from_be_bytes($self.stream.get(1, 4)) - 4) as usize;
read_packet!($(@$blocking)? @stream $self, 5, size);