Skip to content

Commit

Permalink
Merge branch 'PHP-5.6' into PHP-7.0
Browse files Browse the repository at this point in the history
  • Loading branch information
cmb69 committed Jul 23, 2016
2 parents 03ccd42 + 88838dd commit 2c0a184
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 28 deletions.
1 change: 1 addition & 0 deletions NEWS
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ PHP NEWS
. Fixed bug #43828 (broken transparency of imagearc for truecolor in
blendingmode). (cmb)
. Fixed bug #66555 (Always false condition in ext/gd/libgd/gdkanji.c). (cmb)
. Fixed bug #68712 (suspicious if-else statements). (cmb)

- Intl:
. Fixed bug #72639 (Segfault when instantiating class that extends
Expand Down
36 changes: 8 additions & 28 deletions ext/gd/libgd/gd_interpolation.c
Original file line number Diff line number Diff line change
Expand Up @@ -1509,13 +1509,8 @@ gdImagePtr gdImageScaleBicubicFixed(gdImagePtr src, const unsigned int width, co
src_offset_y[0] = m;
}

if (m < 1) {
src_offset_x[1] = n;
src_offset_y[1] = m;
} else {
src_offset_x[1] = n;
src_offset_y[1] = m;
}
src_offset_x[1] = n;
src_offset_y[1] = m;

if ((m < 1) || (n >= src_w - 1)) {
src_offset_x[2] = n;
Expand Down Expand Up @@ -1567,13 +1562,8 @@ gdImagePtr gdImageScaleBicubicFixed(gdImagePtr src, const unsigned int width, co
src_offset_y[8] = m;
}

if (m >= src_h - 1) {
src_offset_x[9] = n;
src_offset_y[9] = m;
} else {
src_offset_x[9] = n;
src_offset_y[9] = m;
}
src_offset_x[9] = n;
src_offset_y[9] = m;

if ((m >= src_h-1) || (n >= src_w-1)) {
src_offset_x[10] = n;
Expand All @@ -1599,13 +1589,8 @@ gdImagePtr gdImageScaleBicubicFixed(gdImagePtr src, const unsigned int width, co
src_offset_y[12] = m;
}

if (m >= src_h - 2) {
src_offset_x[13] = n;
src_offset_y[13] = m;
} else {
src_offset_x[13] = n;
src_offset_y[13] = m;
}
src_offset_x[13] = n;
src_offset_y[13] = m;

if ((m >= src_h - 2) || (n >= src_w - 1)) {
src_offset_x[14] = n;
Expand Down Expand Up @@ -2014,13 +1999,8 @@ gdImagePtr gdImageRotateBicubicFixed(gdImagePtr src, const float degrees, const
src_offset_y[0] = m;
}

if (m < 1) {
src_offset_x[1] = n;
src_offset_y[1] = m;
} else {
src_offset_x[1] = n;
src_offset_y[1] = m ;
}
src_offset_x[1] = n;
src_offset_y[1] = m;

if ((m < 1) || (n >= src_w-1)) {
src_offset_x[2] = - 1;
Expand Down

0 comments on commit 2c0a184

Please sign in to comment.