mirror of
https://github.com/espressif/esp-idf.git
synced 2025-12-25 21:03:54 +00:00
fix(http_server): Removed the build failure due to unused variables
There were build failure due the unused variable last_error when ESP_HTTPS_SERVER_EVENTS and HTTPD_ENABLE_EVENTS are disabled
This commit is contained in:
committed by
Mahavir Jain
parent
bd85dad2cf
commit
bdf438f0aa
@@ -20,6 +20,7 @@ extern "C" {
|
||||
|
||||
#if CONFIG_ESP_HTTPS_SERVER_EVENTS || __DOXYGEN__
|
||||
ESP_EVENT_DECLARE_BASE(ESP_HTTPS_SERVER_EVENT);
|
||||
#endif // CONFIG_ESP_HTTPS_SERVER_EVENTS || __DOXYGEN__
|
||||
|
||||
typedef enum {
|
||||
HTTPS_SERVER_EVENT_ERROR = 0, /*!< This event occurs when there are any errors during execution */
|
||||
@@ -30,7 +31,6 @@ typedef enum {
|
||||
HTTPS_SERVER_EVENT_DISCONNECTED, /*!< The connection has been disconnected */
|
||||
HTTPS_SERVER_EVENT_STOP, /*!< This event occurs when HTTPS Server is stopped */
|
||||
} esp_https_server_event_id_t;
|
||||
#endif // CONFIG_ESP_HTTPS_SERVER_EVENTS || __DOXYGEN__
|
||||
|
||||
typedef enum {
|
||||
HTTPD_SSL_TRANSPORT_SECURE, // SSL Enabled
|
||||
|
||||
@@ -40,7 +40,13 @@ static void http_dispatch_event_to_event_loop(int32_t event_id, const void* even
|
||||
}
|
||||
}
|
||||
#else // CONFIG_ESP_HTTPS_SERVER_EVENTS
|
||||
#define http_dispatch_event_to_event_loop(event_id, event_data, event_data_size) do {} while (0)
|
||||
static void http_dispatch_event_to_event_loop(int32_t event_id, const void* event_data, size_t event_data_size)
|
||||
{
|
||||
// Events disabled, do nothing
|
||||
(void) event_id;
|
||||
(void) event_data;
|
||||
(void) event_data_size;
|
||||
}
|
||||
#endif // CONFIG_ESP_HTTPS_SERVER_EVENTS
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user