esp_http_client: Do not overwrite HTTP method in case of chunk request

Closes https://github.com/espressif/esp-idf/issues/6234
This commit is contained in:
Shubham Kulkarni 2021-03-24 14:17:06 +05:30 committed by bot
parent aecfbf966c
commit 1bacc13628

View File

@ -1173,7 +1173,6 @@ static int http_client_prepare_first_line(esp_http_client_handle_t client, int w
http_header_set_format(client->request->headers, "Content-Length", "%d", write_len);
} else {
esp_http_client_set_header(client, "Transfer-Encoding", "chunked");
esp_http_client_set_method(client, HTTP_METHOD_POST);
}
const char *method = HTTP_METHOD_MAPPING[client->connection_info.method];