]> granicus.if.org Git - imagemagick/commitdiff
...
authorCristy <urban-warrior@imagemagick.org>
Sat, 3 Feb 2018 01:47:11 +0000 (20:47 -0500)
committerCristy <urban-warrior@imagemagick.org>
Sat, 3 Feb 2018 01:47:11 +0000 (20:47 -0500)
MagickCore/draw.c

index 7f65afc9b01dddd39cc125a4ad233860c7f1f7c4..8f92fbc4da9accaa5b4fd9727d74da1379099978 100644 (file)
@@ -3029,19 +3029,21 @@ MagickExport MagickBooleanType DrawImage(Image *image,const DrawInfo *draw_info,
         double
           alpha,
           beta,
+          coordinates,
           radius;
 
         alpha=bounds.x2-bounds.x1;
         beta=bounds.y2-bounds.y1;
         radius=hypot(alpha,beta);
-        if (points_extent > 21400)
+        coordinates=ceil(MagickPI*MagickPI*radius)+6*BezierQuantum+360;
+        if (coordinates > 21400)
           {
             (void) ThrowMagickException(exception,GetMagickModule(),DrawError,
               "TooManyBezierCoordinates","`%s'",token);
             status=MagickFalse;
             break;
           }
-        points_extent=ceil(MagickPI*MagickPI*radius)+6*BezierQuantum+360;
+        points_extent=coordinates;
         break;
       }
       default: