fix(esp_http_client): fix dispatching of finish event condition

This commit updates the condition for dispatching of FINISH event.
With this, FINISH event will be dispatched after complete data is read.

Closes https://github.com/espressif/esp-idf/issues/17437
This commit is contained in:
nilesh.kale
2025-08-29 11:24:54 +05:30
parent f0ab806e7e
commit c09bb9fe46
2 changed files with 4 additions and 4 deletions
@@ -40,7 +40,7 @@ typedef enum {
and will be deprecated in future versions esp-idf */
HTTP_EVENT_ON_HEADER, /*!< Occurs when receiving each header sent from the server */
HTTP_EVENT_ON_DATA, /*!< Occurs when receiving data from the server, possibly multiple portions of the packet */
HTTP_EVENT_ON_FINISH, /*!< Occurs when finish a HTTP session */
HTTP_EVENT_ON_FINISH, /*!< Occurs when complete data is received */
HTTP_EVENT_DISCONNECTED, /*!< The connection has been disconnected */
HTTP_EVENT_REDIRECT, /*!< Intercepting HTTP redirects to handle them manually */
} esp_http_client_event_id_t;