X-Git-Url: https://git.nihav.org/?a=blobdiff_plain;f=src%2Fio%2Fbyteio.rs;h=ca591acf7f10ad94d8564b489ed4b6cf9fd92ed8;hb=e3ace094c509bd04b3b15109c943a4a2419530e1;hp=497e8cc9ce1f3331da5c31ba5e681a2a2b3464f3;hpb=96c6be977343471ee20e442bee42d93949421451;p=nihav.git diff --git a/src/io/byteio.rs b/src/io/byteio.rs index 497e8cc..ca591ac 100644 --- a/src/io/byteio.rs +++ b/src/io/byteio.rs @@ -13,7 +13,7 @@ pub enum ByteIOError { SeekError, } -type ByteIOResult = Result; +pub type ByteIOResult = Result; pub trait ByteIO { fn read_buf(&mut self, buf: &mut [u8]) -> ByteIOResult; @@ -166,7 +166,7 @@ impl<'a> ByteReader<'a> { } else { let mut ssize = len; let mut buf : [u8; 16] = [0; 16]; - let mut bref = &mut buf; + let bref = &mut buf; while ssize > bref.len() { self.io.read_buf(bref)?; ssize -= bref.len();