File php-CVE-2015-8877.patch of Package php5.openSUSE_Leap_42.1_Update
X-Git-Url: http://72.52.91.13:8000/?p=php-src.git;a=blobdiff_plain;f=ext%2Fgd%2Flibgd%2Fgd_interpolation.c;h=32d69f9c205a8158f5c6a7b390effc667a916cf1;hp=f9c8f88e706fcd57909e36abb546f87eab1e1af4;hb=1a4722a89ee85be74af5086a7027b3ad1e0a55e8;hpb=25e5c8ac31df7021d7db3190a53403a55eb04e20
diff --git a/ext/gd/libgd/gd_interpolation.c b/ext/gd/libgd/gd_interpolation.c
index f9c8f88..32d69f9 100644
--- a/ext/gd/libgd/gd_interpolation.c
+++ b/ext/gd/libgd/gd_interpolation.c
@@ -1073,12 +1073,12 @@ gdImagePtr gdImageScaleTwoPass(const gdImagePtr src, const unsigned int src_widt
dst = gdImageCreateTrueColor(new_width, new_height);
if (dst == NULL) {
- gdFree(tmp_im);
+ gdImageDestroy(tmp_im);
return NULL;
}
gdImageSetInterpolationMethod(dst, src->interpolation_id);
_gdScaleVert(tmp_im, new_width, src_height, dst, new_width, new_height);
- gdFree(tmp_im);
+ gdImageDestroy(tmp_im);
return dst;
}