diff --git a/src/decoder/mod.rs b/src/decoder/mod.rs index 4d8d2c01..8a76200c 100644 --- a/src/decoder/mod.rs +++ b/src/decoder/mod.rs @@ -713,10 +713,8 @@ impl Reader { } match self.decoder.decode_next(&mut self.data_stream)? { - Some(Decoded::ImageData) => {} - Some(Decoded::ImageDataFlushed) | None /* after IEND chunk */ => { - self.subframe.consumed_and_flushed = true; - } + Some(Decoded::ImageData) => (), + Some(Decoded::ImageDataFlushed) => self.subframe.consumed_and_flushed = true, _ => (), } }