From: Michael Wallner Date: Wed, 9 Mar 2016 09:56:20 +0000 (+0100) Subject: Merge branch 'v2.5.x' X-Git-Tag: RELEASE_3_0_1~1 X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=e57370d1f00da9e12de0917a9f907281ab8e84b5;p=m6w6%2Fext-http Merge branch 'v2.5.x' --- e57370d1f00da9e12de0917a9f907281ab8e84b5 diff --cc src/php_http_client_curl.c index e79ef15,f49aabc..e56f8d4 --- a/src/php_http_client_curl.c +++ b/src/php_http_client_curl.c @@@ -1484,8 -1469,8 +1484,8 @@@ static void php_http_curle_options_init ZVAL_BOOL(&opt->defval, 1); opt->setter = php_http_curle_option_set_ssl_verifyhost; } - #if PHP_HTTP_CURL_VERSION(7,41,0) + #if PHP_HTTP_CURL_VERSION(7,41,0) && (defined(PHP_HTTP_HAVE_OPENSSL) || defined(PHP_HTTP_HAVE_NSS) || defined(PHP_HTTP_HAVE_GNUTLS)) - php_http_option_register(registry, ZEND_STRL("verifystatus"), CURLOPT_SSL_VERIFYSTATUS, IS_BOOL); + php_http_option_register(registry, ZEND_STRL("verifystatus"), CURLOPT_SSL_VERIFYSTATUS, _IS_BOOL); #endif php_http_option_register(registry, ZEND_STRL("cipher_list"), CURLOPT_SSL_CIPHER_LIST, IS_STRING); if ((opt = php_http_option_register(registry, ZEND_STRL("cainfo"), CURLOPT_CAINFO, IS_STRING))) { diff --cc src/php_http_url.c index 4009add,07121df..3ed2e3c --- a/src/php_http_url.c +++ b/src/php_http_url.c @@@ -1495,9 -1496,9 +1496,9 @@@ softfail return state->ptr = tmp; } -php_http_url_t *php_http_url_parse(const char *str, size_t len, unsigned flags TSRMLS_DC) +php_http_url_t *php_http_url_parse(const char *str, size_t len, unsigned flags) { - size_t maxlen = 3 * len; + size_t maxlen = 3 * len + 8 /* null bytes for all components */; struct parse_state *state = ecalloc(1, sizeof(*state) + maxlen); state->end = str + len;