*/
#define BezierQuantum 200
#define DrawEpsilon (1.0e-10)
-#define MaxBezierCoordinates 2097152
+#define MaxBezierCoordinates 262144
#define ThrowPointExpectedException(token,exception) \
{ \
(void) ThrowMagickException(exception,GetMagickModule(),DrawError, \
dx=primitive_info[i].point.x-primitive_info[i-1].point.x;
dy=primitive_info[i].point.y-primitive_info[i-1].point.y;
maximum_length=hypot(dx,dy);
- if (maximum_length > MaxBezierCoordinates)
- break;
if (fabs(length) < DrawEpsilon)
{
n++;
if (coordinates > MaxBezierCoordinates)
{
(void) ThrowMagickException(exception,GetMagickModule(),
- ResourceLimitError,"MemoryAllocationFailed","`%s'",token);
+ DrawError,"TooManyBezierCoordinates","`%s'",token);
status=MagickFalse;
}
if (status == MagickFalse)