From 561c5d82a77366758c13b4f1095cae9aa271c88e Mon Sep 17 00:00:00 2001 From: Ildar Khayrutdinov Date: Mon, 20 Feb 2023 11:23:23 +0300 Subject: [PATCH] assert not supported ink names --- src/ImageSharp/Formats/Tiff/TiffDecoderOptionsParser.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/ImageSharp/Formats/Tiff/TiffDecoderOptionsParser.cs b/src/ImageSharp/Formats/Tiff/TiffDecoderOptionsParser.cs index a13fb58de7..26905965ee 100644 --- a/src/ImageSharp/Formats/Tiff/TiffDecoderOptionsParser.cs +++ b/src/ImageSharp/Formats/Tiff/TiffDecoderOptionsParser.cs @@ -509,6 +509,11 @@ internal static class TiffDecoderOptionsParser TiffThrowHelper.ThrowNotSupported("Only 8 bits per channel is supported for CMYK images."); } + if (exifProfile.GetValueInternal(ExifTag.InkNames) is not null) + { + TiffThrowHelper.ThrowNotSupported("The custom ink name strings are not supported for CMYK images."); + } + options.ColorType = TiffColorType.Cmyk; break; }