From 76d9412416427985fe1f27e590f3f89c110691a5 Mon Sep 17 00:00:00 2001 From: mkehoe Date: Sat, 8 Jan 2022 21:56:39 -0800 Subject: [PATCH] Fix for Jpeg Metadata Decoding with unknown APP13 profile --- src/ImageSharp/Formats/Jpeg/JpegDecoderCore.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/ImageSharp/Formats/Jpeg/JpegDecoderCore.cs b/src/ImageSharp/Formats/Jpeg/JpegDecoderCore.cs index 73af42afd4..77e1301cd3 100644 --- a/src/ImageSharp/Formats/Jpeg/JpegDecoderCore.cs +++ b/src/ImageSharp/Formats/Jpeg/JpegDecoderCore.cs @@ -788,6 +788,11 @@ namespace SixLabors.ImageSharp.Formats.Jpeg } } } + else + { + // If the profile is unknown skip over the rest of it. + stream.Skip(remaining); + } } ///