]> granicus.if.org Git - php/commitdiff
- Fix #30739, imagefill does not set back the alphablending mode
authorPierre Joye <pajoye@php.net>
Wed, 17 Nov 2004 17:13:42 +0000 (17:13 +0000)
committerPierre Joye <pajoye@php.net>
Wed, 17 Nov 2004 17:13:42 +0000 (17:13 +0000)
NEWS
ext/gd/libgd/gd.c

diff --git a/NEWS b/NEWS
index 1deb1a5eefa2332f3e403b4bfc610c44ba608a8d..1b02e8d0dde9c46230199615c362a8e50d297d7a 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -8,6 +8,7 @@ PHP 4                                                                      NEWS
 - Fixed potential problems with unserializing invalid serialize data. (Marcus)
 - Fixed bug #30750 (Meaningful error message when upload directory is not 
   accessible). (Ilia)
+- Fixed bug #30739 (imagefill does not set back alphablending mode) (Pierre)
 - Fixed bug #30672 (Problem handling exif data in jpeg images at unusual 
   places). (Marcus)
 - Fixed bug #30658 (Ensure that temporary files created by GD are removed).
index 4ee4a442fcfd6a79dbf75b08ef8f3a5b48f1b5c5..93a70bff86048ca860ff8c867908af47e91d2b68 100644 (file)
@@ -1896,8 +1896,11 @@ void gdImageFill(gdImagePtr im, int x, int y, int nc)
 
        wx2=im->sx;wy2=im->sy;
        oc = gdImageGetPixel(im, x, y);
-       if (oc==nc || x<0 || x>wx2 || y<0 || y>wy2) return;
-
+       if (oc==nc || x<0 || x>wx2 || y<0 || y>wy2) {
+               im->alphaBlendingFlag = alphablending_bak;      
+               return;
+       }
        stack = (struct seg *)emalloc(sizeof(struct seg) * ((int)(im->sy*im->sx)/4)+1);
        sp = stack;