diff --git a/wand/mogrify.c b/wand/mogrify.c index 029c13ba72..e5c1ce95be 100644 --- a/wand/mogrify.c +++ b/wand/mogrify.c @@ -8711,7 +8711,7 @@ WandExport MagickBooleanType MogrifyImageList(ImageInfo *image_info, (void) SyncImagesSettings(mogrify_info,*images); arguments=StringToArgv(argv[i+1],&number_arguments); - if (arguments == (char **) NULL) + if ((arguments == (char **) NULL) || (number_arguments == 1)) break; if ((argc > 1) && (strchr(arguments[1],'=') != (char *) NULL)) {