Merge branch 'feat/add_support_to_add_auth_data_v5.1' into 'release/v5.1'

fix(esp_http_client): Call event_handler after header value is received (v5.1)

See merge request espressif/esp-idf!26321
This commit is contained in:
Mahavir Jain 2023-10-17 18:08:12 +08:00
commit 5d4249ec99

View File

@ -233,7 +233,6 @@ static int http_on_header_event(esp_http_client_handle_t client)
static int http_on_header_field(http_parser *parser, const char *at, size_t length)
{
esp_http_client_t *client = parser->data;
http_on_header_event(client);
http_utils_append_string(&client->current_header_key, at, length);
return 0;
@ -254,6 +253,7 @@ static int http_on_header_value(http_parser *parser, const char *at, size_t leng
http_utils_append_string(&client->auth_header, at, length);
}
http_utils_append_string(&client->current_header_value, at, length);
http_on_header_event(client);
return 0;
}