From: Michael Wallner Date: Thu, 25 Sep 2014 07:17:42 +0000 (+0200) Subject: Fix bug #68083 PUT method not working after DELETE X-Git-Tag: RELEASE_2_1_2~2 X-Git-Url: https://git.m6w6.name/?p=m6w6%2Fext-http;a=commitdiff_plain;h=d9c22b8c6b2c3f6e2e6feffe77f940b3fe20efe5 Fix bug #68083 PUT method not working after DELETE properly reset curl's request method bits --- diff --git a/php_http_client_curl.c b/php_http_client_curl.c index 5c1fecd..6f9884e 100644 --- a/php_http_client_curl.c +++ b/php_http_client_curl.c @@ -1496,6 +1496,9 @@ static STATUS php_http_client_curl_handler_reset(php_http_client_curl_handler_t } curl_easy_setopt(ch, CURLOPT_URL, NULL); + curl_easy_setopt(ch, CURLOPT_CUSTOMREQUEST, NULL); + curl_easy_setopt(ch, CURLOPT_HTTPGET, 1L); + curl_easy_setopt(ch, CURLOPT_NOBODY, 0L); /* libcurl < 7.19.6 does not clear auth info with USERPWD set to NULL */ #if PHP_HTTP_CURL_VERSION(7,19,1) curl_easy_setopt(ch, CURLOPT_PROXYUSERNAME, NULL);