From bc505410f80162dda82f7c0dbef6a60d4bbbe769 Mon Sep 17 00:00:00 2001 From: Mex <44814932+MMexicann@users.noreply.github.com> Date: Sat, 14 Nov 2026 20:18:24 +0100 Subject: [PATCH] fix(xfa): remove redundant defaults from codec options --- crates/xfa/src/image.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/xfa/src/image.rs b/crates/xfa/src/image.rs index ce40dfa6b0..2a6d0ddbf5 100644 --- a/crates/xfa/src/image.rs +++ b/crates/xfa/src/image.rs @@ -169,7 +169,7 @@ pub fn decode(data: &[u8]) -> Result { } match kind(data) { Some(Kind::Png) => { - let opts = craft_image_codecs::DecodeOptions { keep_orientation: true, limits: decode_limits(), ..Default::default() }; + let opts = craft_image_codecs::DecodeOptions { keep_orientation: true, limits: decode_limits() }; let img = craft_image_codecs::decode_as_with(craft_image_codecs::Format::Png, data, &opts).map_err(|e| match e { craft_image_codecs::CodecError::LimitExceeded(_) => too_big(), other => bad(other.to_string()), @@ -212,7 +212,7 @@ pub fn decode(data: &[u8]) -> Result { _ => craft_image_codecs::Format::Tiff, }; let data = if k == Kind::Bmp { bmp_with_pixel_offset(data) } else { std::borrow::Cow::Borrowed(data) }; - let opts = craft_image_codecs::DecodeOptions { keep_orientation: false, limits: decode_limits(), ..Default::default() }; + let opts = craft_image_codecs::DecodeOptions { keep_orientation: false, limits: decode_limits() }; let img = craft_image_codecs::decode_as_with(format, &data, &opts).map_err(|e| match e { craft_image_codecs::CodecError::LimitExceeded(_) => too_big(), other => bad(other.to_string()),