From: Michael Wallner Date: Thu, 5 Feb 2015 15:26:19 +0000 (+0100) Subject: ensure options are applied before the headers are set X-Git-Tag: RELEASE_2_3_0_RC1~55 X-Git-Url: https://git.m6w6.name/?p=m6w6%2Fext-http;a=commitdiff_plain;h=791511f3bc18cdc68b3f27b43d9396cf56d99e5a;hp=225ce54f0baaf9f840c952d9f2e7bfc52aae0981 ensure options are applied before the headers are set --- diff --git a/php_http_client_curl.c b/php_http_client_curl.c index 8aaeaa0..e92834d 100644 --- a/php_http_client_curl.c +++ b/php_http_client_curl.c @@ -1743,6 +1743,9 @@ static STATUS php_http_client_curl_handler_prepare(php_http_client_curl_handler_ } } + /* apply options */ + php_http_options_apply(&php_http_curle_options, enqueue->options, curl); + /* request headers */ php_http_message_update_headers(msg); if (zend_hash_num_elements(&msg->hdrs)) { @@ -1798,8 +1801,6 @@ static STATUS php_http_client_curl_handler_prepare(php_http_client_curl_handler_ curl_easy_setopt(curl->handle, CURLOPT_POSTFIELDSIZE, 0L); } - php_http_options_apply(&php_http_curle_options, enqueue->options, curl); - return SUCCESS; }