esp_wifi_deinit: Return ESP_ERR_WIFI_NOT_STOPPED if wifi is not stopped

Add test case to test this workflow
This commit is contained in:
Shubham Kulkarni
2021-02-04 20:55:48 +05:30
parent d3bd190528
commit cbe281130d
2 changed files with 54 additions and 1 deletions

View File

@@ -133,7 +133,7 @@ esp_err_t esp_wifi_deinit(void)
if (esp_wifi_get_user_init_flag_internal()) {
ESP_LOGE(TAG, "Wi-Fi not stop");
return ESP_FAIL;
return ESP_ERR_WIFI_NOT_STOPPED;
}
esp_supplicant_deinit();