change from deprecated Buf::put_*<E> to put_*_be (#267)
This commit is contained in:
committed by
Carl Lerche
parent
fadec67fdf
commit
e8fcd34476
@@ -1,6 +1,6 @@
|
||||
use super::StreamId;
|
||||
|
||||
use bytes::{BigEndian, BufMut};
|
||||
use bytes::{BufMut};
|
||||
|
||||
#[derive(Debug, Copy, Clone, PartialEq, Eq)]
|
||||
pub struct Head {
|
||||
@@ -66,10 +66,10 @@ impl Head {
|
||||
pub fn encode<T: BufMut>(&self, payload_len: usize, dst: &mut T) {
|
||||
debug_assert!(self.encode_len() <= dst.remaining_mut());
|
||||
|
||||
dst.put_uint::<BigEndian>(payload_len as u64, 3);
|
||||
dst.put_uint_be(payload_len as u64, 3);
|
||||
dst.put_u8(self.kind as u8);
|
||||
dst.put_u8(self.flag);
|
||||
dst.put_u32::<BigEndian>(self.stream_id.into());
|
||||
dst.put_u32_be(self.stream_id.into());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user