We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5c6eaec commit 1be8e37Copy full SHA for 1be8e37
src/gz/mod.rs
@@ -252,9 +252,7 @@ fn read_to_nul<R: BufRead>(r: &mut R, buffer: &mut Vec<u8>) -> Result<()> {
252
let mut bytes = r.bytes();
253
loop {
254
match bytes.next().transpose()? {
255
- Some(byte) if byte == 0 => {
256
- return Ok(());
257
- }
+ Some(0) => return Ok(()),
258
Some(_) if buffer.len() == MAX_HEADER_BUF => {
259
return Err(Error::new(
260
ErrorKind::InvalidInput,
0 commit comments