From: Dirk Lemstra Date: Sat, 24 Nov 2018 06:40:22 +0000 (+0100) Subject: Removed incorrect detection of the alpha channel for the merged image. X-Git-Tag: 7.0.8-15~51 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=278785e14573a2d86eea270c74e6b37de68bd976;p=imagemagick Removed incorrect detection of the alpha channel for the merged image. --- diff --git a/coders/psd.c b/coders/psd.c index 5df18a9cb..8148281da 100644 --- a/coders/psd.c +++ b/coders/psd.c @@ -2172,8 +2172,6 @@ static Image *ReadPSDImage(const ImageInfo *image_info,ExceptionInfo *exception) { psd_info.min_channels=4; (void) SetImageColorspace(image,CMYKColorspace,exception); - if (psd_info.channels > 4) - (void) SetImageAlphaChannel(image,ActivateAlphaChannel,exception); } else if ((psd_info.mode == BitmapMode) || (psd_info.mode == GrayscaleMode) || (psd_info.mode == DuotoneMode)) @@ -2190,12 +2188,7 @@ static Image *ReadPSDImage(const ImageInfo *image_info,ExceptionInfo *exception) } psd_info.min_channels=1; (void) SetImageColorspace(image,GRAYColorspace,exception); - if (psd_info.channels > 1) - (void) SetImageAlphaChannel(image,ActivateAlphaChannel,exception); } - else - if (psd_info.channels > 3) - (void) SetImageAlphaChannel(image,ActivateAlphaChannel,exception); if (psd_info.channels < psd_info.min_channels) ThrowReaderException(CorruptImageError,"ImproperImageHeader"); /*