com php-src: followup with #73276 merge: ext/openssl/openssl.c

From: Date: Wed, 12 Oct 2016 14:03:35 +0000
Subject: com php-src: followup with #73276 merge: ext/openssl/openssl.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-94943@lists.php.net to get a copy of this message
Commit: b135ba3fa93fd4f085322573d2850b29cb662e21 Author: Anatol Belski <ab@php.net> Wed, 12 Oct 2016 16:03:35 +0200 Parents: 7c6cb1282d539c4d5ff5adc8f7a6926c83b98e20 Branches: PHP-7.0 PHP-7.1 master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=b135ba3fa93fd4f085322573d2850b29cb662e21 Log: followup with #73276 merge Bugs: https://bugs.php.net/73276 Changed paths: M ext/openssl/openssl.c Diff: diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c index bf1f0c5..648b110 100644 --- a/ext/openssl/openssl.c +++ b/ext/openssl/openssl.c @@ -5546,6 +5546,11 @@ PHP_FUNCTION(openssl_random_pseudo_bytes) return; } + if (zstrong_result_returned) { + zval_dtor(zstrong_result_returned); + ZVAL_FALSE(zstrong_result_returned); + } + if (buffer_length <= 0 #ifndef PHP_WIN32 || ZEND_LONG_INT_OVFL(buffer_length) @@ -5553,12 +5558,6 @@ PHP_FUNCTION(openssl_random_pseudo_bytes) ) { RETURN_FALSE; } - - if (zstrong_result_returned) { - zval_dtor(zstrong_result_returned); - ZVAL_FALSE(zstrong_result_returned); - } - buffer = zend_string_alloc(buffer_length, 0); #ifdef PHP_WIN32

« previous php.cvs (#94943) next »