From 684c5d1d5b7091dac726f667c5e6a7046d66850e Mon Sep 17 00:00:00 2001 From: Cristy Date: Tue, 17 Apr 2018 20:11:58 -0400 Subject: [PATCH] https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=7733 --- MagickCore/fx.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/MagickCore/fx.c b/MagickCore/fx.c index 1b007cdcc..28b4f255b 100644 --- a/MagickCore/fx.c +++ b/MagickCore/fx.c @@ -1281,7 +1281,6 @@ static double FxGetSymbol(FxInfo *fx_info,const PixelChannel channel, i; size_t - length, level; p=expression; @@ -1395,11 +1394,6 @@ static double FxGetSymbol(FxInfo *fx_info,const PixelChannel channel, } subexpression=DestroyString(subexpression); } - length=GetImageListLength(fx_info->images); - while (i < 0) - i+=(ssize_t) length; - if (length != 0) - i%=length; image=GetImageFromList(fx_info->images,i); if (image == (Image *) NULL) { @@ -1407,6 +1401,7 @@ static double FxGetSymbol(FxInfo *fx_info,const PixelChannel channel, "NoSuchImage","`%s'",expression); return(0.0); } + i=GetImageIndexInList(image); GetPixelInfo(image,&pixel); status=InterpolatePixelInfo(image,fx_info->view[i],image->interpolate, point.x,point.y,&pixel,exception); -- 2.40.0