pub fn slice_to_buf<B>(s: &[u8]) -> Bwhere B: Default + BufMut,
Converts a byte slice to a buffer by copying.