From: Michael Wallner Date: Fri, 24 Mar 2006 18:35:18 +0000 (+0000) Subject: * Fixed Bug #7192: Build against libcurl >= 7.15.2 fails X-Git-Tag: RELEASE_1_0_0RC3~33 X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=6625caa572df4f04564706b0b8200cd9f03adadf;p=m6w6%2Fext-http * Fixed Bug #7192: Build against libcurl >= 7.15.2 fails --- diff --git a/http_request_api.c b/http_request_api.c index 922f7a9..6d21d9b 100644 --- a/http_request_api.c +++ b/http_request_api.c @@ -557,7 +557,7 @@ PHP_HTTP_API STATUS _http_request_prepare(http_request *request, HashTable *opti #if HTTP_CURL_VERSION(7,15,2) if ((zoption = http_request_option(request, options, "portrange", IS_ARRAY))) { - zval *prs, *pre; + zval **prs, **pre; zend_hash_internal_pointer_reset(Z_ARRVAL_P(zoption)); if (SUCCESS == zend_hash_get_current_data(Z_ARRVAL_P(zoption), (void **) &prs)) { @@ -566,8 +566,9 @@ PHP_HTTP_API STATUS _http_request_prepare(http_request *request, HashTable *opti zval *prs_cpy = zval_copy(IS_LONG, *prs), *pre_cpy = zval_copy(IS_LONG, *pre); if (Z_LVAL_P(prs_cpy) && Z_LVAL_P(pre_cpy)) { + fprintf(stderr, "Using portrange: %ld-%ld\n", Z_LVAL_P(prs_cpy), Z_LVAL_P(pre_cpy)); HTTP_CURL_OPT(CURLOPT_LOCALPORT, MIN(Z_LVAL_P(prs_cpy), Z_LVAL_P(pre_cpy))); - HTTP_CURL_OPT(CURLOPT_LOCALPORTRANGE, ABS(Z_LVAL_P(prs_cpy)-Z_LVAL_P(pre_cpy))+1L); + HTTP_CURL_OPT(CURLOPT_LOCALPORTRANGE, labs(Z_LVAL_P(prs_cpy)-Z_LVAL_P(pre_cpy))+1L); } zval_free(&prs_cpy); zval_free(&pre_cpy); diff --git a/package2.xml b/package2.xml index 3fba4a9..cc99e7d 100644 --- a/package2.xml +++ b/package2.xml @@ -37,7 +37,7 @@ HttpResponse 2006-00-00 - 1.0.0RC1 + 1.0.0RC2 1.0.0 @@ -46,11 +46,7 @@ HttpResponse BSD, revised = 7.15.2 fails ]]> diff --git a/php_http.h b/php_http.h index 2782a73..7244c85 100644 --- a/php_http.h +++ b/php_http.h @@ -15,7 +15,7 @@ #ifndef PHP_EXT_HTTP_H #define PHP_EXT_HTTP_H -#define PHP_EXT_HTTP_VERSION "1.0.0RC1" +#define PHP_EXT_HTTP_VERSION "1.0.0RC2-dev" #ifdef HAVE_CONFIG_H # include "config.h"