mirror of
https://github.com/espressif/esp-idf.git
synced 2025-08-11 04:57:38 +00:00
Don't ignore return value of httpd_stop
This commit is contained in:
@@ -182,10 +182,10 @@ static httpd_handle_t start_webserver(void)
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static void stop_webserver(httpd_handle_t server)
|
||||
static esp_err_t stop_webserver(httpd_handle_t server)
|
||||
{
|
||||
// Stop the httpd server
|
||||
httpd_stop(server);
|
||||
return httpd_stop(server);
|
||||
}
|
||||
|
||||
|
||||
@@ -195,8 +195,8 @@ static void disconnect_handler(void* arg, esp_event_base_t event_base,
|
||||
httpd_handle_t* server = (httpd_handle_t*) arg;
|
||||
if (*server) {
|
||||
ESP_LOGI(TAG, "Stopping webserver");
|
||||
stop_webserver(*server);
|
||||
*server = NULL;
|
||||
if (stop_webserver(*server) == ESP_OK)
|
||||
*server = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user