com php-src: Better fix for #71952: ext/gd/gd.c

From: Date: Thu, 28 Apr 2016 00:27:47 +0000
Subject: com php-src: Better fix for #71952: ext/gd/gd.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-91901@lists.php.net to get a copy of this message
Commit: 1d4877b3b3b290aa68482e6358c37097a670355f Author: Stanislav Malyshev <stas@php.net> Tue, 19 Apr 2016 23:44:00 -0700 Committer: Ferenc Kovacs <tyrael@php.net> Thu, 28 Apr 2016 02:27:47 +0200 Parents: 0cc5e91d529cd8bbcbf277f950ee30026b3c5454 Branches: PHP-5.6.21 Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=1d4877b3b3b290aa68482e6358c37097a670355f Log: Better fix for #71952 Bugs: https://bugs.php.net/71952 Changed paths: M ext/gd/gd.c Diff: diff --git a/ext/gd/gd.c b/ext/gd/gd.c index df0a32f..0fce8dd 100644 --- a/ext/gd/gd.c +++ b/ext/gd/gd.c @@ -5363,10 +5363,14 @@ PHP_FUNCTION(imageaffinematrixget) RETURN_FALSE; } if(Z_TYPE_P(options) != IS_DOUBLE) { - Z_ADDREF_P(options); - convert_to_double_ex(&options); + zval dval; + dval = *options; + zval_copy_ctor(&dval); + convert_to_double(&dval); + angle = Z_DVAL(dval); + } else { + angle = Z_DVAL_P(options); } - angle = Z_DVAL_P(options); if (type == GD_AFFINE_SHEAR_HORIZONTAL) { res = gdAffineShearHorizontal(affine, angle);

« previous php.cvs (#91901) next »