mirror of
https://github.com/zerotier/common-utils.git
synced 2026-05-22 16:28:56 -07:00
fixed create from
This commit is contained in:
+1
-1
@@ -48,7 +48,7 @@ impl Buf {
|
||||
}
|
||||
}
|
||||
pub fn create_from(buffer: &[u8]) -> Buf {
|
||||
let mut buf = Self::new(buffer.len());
|
||||
let mut buf = Self::new((buffer.len() + 7)/8*8);
|
||||
let _ = buf.append(buffer);
|
||||
buf
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user