From fecf247fb9a6eae8fc719b413553822bc3d1fe78 Mon Sep 17 00:00:00 2001 From: Cristy Date: Sun, 1 May 2022 13:00:47 -0400 Subject: [PATCH] the tiles per page cannot be zero --- coders/ashlar.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/coders/ashlar.c b/coders/ashlar.c index 40e4bc8996..cbc54ffef8 100644 --- a/coders/ashlar.c +++ b/coders/ashlar.c @@ -695,7 +695,7 @@ static MagickBooleanType WriteASHLARImage(const ImageInfo *image_info, tiles_per_page=GetImageListLength(image); value=GetImageOption(image_info,"ashlar:tiles"); if (value != (const char *) NULL) - tiles_per_page=(size_t) StringToInteger(value); + tiles_per_page=(size_t) MagickMax(StringToInteger(value),1); ashlar_images=NewImageList(); for (i=0; i < (ssize_t) GetImageListLength(image); i+=tiles_per_page) {