Fix support for large images; https://bugs.php.net/bug.php?id=51128 (libgd#177)
parent
6a93f8e362
commit
57ad70b2cd
4
src/gd.c
4
src/gd.c
|
@ -1882,9 +1882,9 @@ struct seg {
|
|||
};
|
||||
|
||||
/* max depth of stack */
|
||||
#define FILL_MAX 1200000
|
||||
#define FILL_MAX ((int)(im->sy*im->sx)/4)
|
||||
#define FILL_PUSH(Y, XL, XR, DY) \
|
||||
if (sp<stack+FILL_MAX*10 && Y+(DY)>=0 && Y+(DY)<wy2) \
|
||||
if (sp<stack+FILL_MAX && Y+(DY)>=0 && Y+(DY)<wy2) \
|
||||
{sp->y = Y; sp->xl = XL; sp->xr = XR; sp->dy = DY; sp++;}
|
||||
|
||||
#define FILL_POP(Y, XL, XR, DY) \
|
||||
|
|
Loading…
Reference in New Issue