]> granicus.if.org Git - php/commitdiff
- restore too the alphablending if we do not reach the end of the function
authorPierre Joye <pajoye@php.net>
Sat, 13 Mar 2004 23:21:25 +0000 (23:21 +0000)
committerPierre Joye <pajoye@php.net>
Sat, 13 Mar 2004 23:21:25 +0000 (23:21 +0000)
  Notice: This function still crashes (stack overflow), to reproduce it
  see bug27582_2.phpt

ext/gd/libgd/gd.c

index cff22915a06bd08958ca2d6876fb12b08f83ba60..4ae2488b1c64b95f6f0cb2eef426d21d4713ecdc 100644 (file)
@@ -1787,6 +1787,9 @@ void gdImageFillToBorder (gdImagePtr im, int x, int y, int border, int color)
                leftLimit = i;
        }
        if (leftLimit == -1) {
+               if (restoreAlphaBleding) {
+                       im->alphaBlendingFlag = 1;
+               }
                return;
        }
        /* Seek right */
@@ -1834,7 +1837,6 @@ void gdImageFillToBorder (gdImagePtr im, int x, int y, int border, int color)
        if (restoreAlphaBleding) {
                im->alphaBlendingFlag = 1;
        }
-
 }
 
 /*