chore: fix new Clippy lints in code that is not usually checked

This commit is contained in:
Alejandro González 2025-12-06 15:59:47 +01:00
parent 9c24b1c8ca
commit 51e8f4f9c2
No known key found for this signature in database
3 changed files with 4 additions and 3 deletions

View file

@ -1,8 +1,9 @@
mod deflater;
use std::{fmt, fmt::Display};
pub use deflater::{crc32, deflate, inflate};
use crate::{PngError, PngResult};
use std::{fmt, fmt::Display};
#[cfg(feature = "zopfli")]
mod zopfli_oxipng;

View file

@ -673,7 +673,7 @@ fn copy_permissions(metadata_input: &Metadata, out_file: &File) -> PngResult<()>
}
#[cfg(not(feature = "filetime"))]
fn copy_times(_: &Metadata, _: &Path) -> PngResult<()> {
const fn copy_times(_: &Metadata, _: &Path) -> PngResult<()> {
Ok(())
}

View file

@ -44,7 +44,7 @@ fn load_png_image_from_memory(png_data: &[u8]) -> Result<Vec<RgbaImage>, image::
decoder
.apng()?
.into_frames()
.map(|f| f.map(|f| f.into_buffer()))
.map(|f| f.map(image::Frame::into_buffer))
.collect()
} else {
DynamicImage::from_decoder(decoder).map(|i| vec![i.into_rgba8()])