eliminate compiler exception

This commit is contained in:
Cristy
2026-01-31 13:23:16 -05:00
parent 9afe96cc32
commit 6f6856b47b
+4 -4
View File
@@ -165,8 +165,8 @@ static Image *ReadYUVImage(const ImageInfo *image_info,ExceptionInfo *exception)
vertical_factor=horizontal_factor;
if ((flags & SigmaValue) != 0)
vertical_factor=(ssize_t) geometry_info.sigma;
if ((horizontal_factor != 1) && (horizontal_factor != 2) ||
(vertical_factor != 1) && (vertical_factor != 2))
if (((horizontal_factor != 1) && (horizontal_factor != 2)) ||
((vertical_factor != 1) && (vertical_factor != 2)))
ThrowReaderException(CorruptImageError,"UnexpectedSamplingFactor");
}
if ((interlace == UndefinedInterlace) ||
@@ -670,8 +670,8 @@ static MagickBooleanType WriteYUVImage(const ImageInfo *image_info,Image *image,
vertical_factor=horizontal_factor;
if ((flags & SigmaValue) != 0)
vertical_factor=(ssize_t) geometry_info.sigma;
if ((horizontal_factor != 1) && (horizontal_factor != 2) ||
(vertical_factor != 1) && (vertical_factor != 2))
if (((horizontal_factor != 1) && (horizontal_factor != 2)) ||
((vertical_factor != 1) && (vertical_factor != 2)))
ThrowWriterException(CorruptImageError,"UnexpectedSamplingFactor");
}
if ((interlace == UndefinedInterlace) ||