1
0
mirror of https://github.com/php/php-src.git synced 2026-04-22 15:38:49 +02:00

Merge branch 'PHP-7.0' into PHP-7.1

This commit is contained in:
Bob Weinand
2017-10-12 12:31:20 +02:00
2 changed files with 4 additions and 9 deletions
+3
View File
@@ -6,6 +6,9 @@ PHP NEWS
. Fixed bug #75301 (Exif extension has built in revision version). (Peter
Kokot)
- Openssl:
. Fixed bug #75363 (openssl_x509_parse leaks memory). (Bob)
- Zlib:
. Fixed bug #75299 (Wrong reflection on inflate_init and inflate_add). (Fabien
Villepinte)
+1 -9
View File
@@ -2280,7 +2280,6 @@ PHP_FUNCTION(openssl_x509_parse)
{
zval * zcert;
X509 * cert = NULL;
zend_resource *certresource = NULL;
int i, sig_nid;
zend_bool useshortnames = 1;
char * tmpstr;
@@ -2300,7 +2299,7 @@ PHP_FUNCTION(openssl_x509_parse)
if (zend_parse_parameters(ZEND_NUM_ARGS(), "z|b", &zcert, &useshortnames) == FAILURE) {
return;
}
cert = php_openssl_x509_from_zval(zcert, 0, &certresource);
cert = php_openssl_x509_from_zval(zcert, 0, NULL);
if (cert == NULL) {
RETURN_FALSE;
}
@@ -2416,9 +2415,6 @@ PHP_FUNCTION(openssl_x509_parse)
add_assoc_stringl(&subitem, extname, bio_buf->data, bio_buf->length);
} else {
zval_dtor(return_value);
if (certresource == NULL && cert) {
X509_free(cert);
}
BIO_free(bio_out);
RETURN_FALSE;
}
@@ -2432,10 +2428,6 @@ PHP_FUNCTION(openssl_x509_parse)
BIO_free(bio_out);
}
add_assoc_zval(return_value, "extensions", &subitem);
if (certresource == NULL && cert) {
X509_free(cert);
}
}
/* }}} */