mirror of
https://github.com/php/php-src.git
synced 2024-11-25 02:44:58 +08:00
- Fix sanity check for the color index in imagecolortransparent
This commit is contained in:
parent
a8c40d5b3a
commit
8f8220917e
1
NEWS
1
NEWS
@ -16,6 +16,7 @@ PHP NEWS
|
||||
- Improved shared extension loading on OSX to use the standard Unix dlopen()
|
||||
API. (Scott)
|
||||
|
||||
- Fixed sanity check for the color index in imagecolortransparent. (Pierre)
|
||||
- Fixed scandir/readdir when used mounted points on Windows. (Pierre)
|
||||
- Fixed zlib.deflate compress filter to actually accept level parameter. (Jani)
|
||||
- Fixed leak on error in popen/exec (and related functions) on Windows.
|
||||
|
@ -595,7 +595,7 @@ void gdImageColorTransparent (gdImagePtr im, int color)
|
||||
if (im->transparent != -1) {
|
||||
im->alpha[im->transparent] = gdAlphaOpaque;
|
||||
}
|
||||
if (color > -1 && color<im->colorsTotal && color<=gdMaxColors) {
|
||||
if (color > -1 && color < im->colorsTotal && color < gdMaxColors) {
|
||||
im->alpha[color] = gdAlphaTransparent;
|
||||
} else {
|
||||
return;
|
||||
|
Loading…
Reference in New Issue
Block a user