fix crash if SD enabled but not inserted and sleep
This commit is contained in:
parent
f3fdfda3fd
commit
c07ca14e20
@ -216,6 +216,8 @@ void sdcard_flush(void) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void sdcard_close(void) {
|
void sdcard_close(void) {
|
||||||
|
if (!useSDCard)
|
||||||
|
return;
|
||||||
ESP_LOGI(TAG, "closing SD-card");
|
ESP_LOGI(TAG, "closing SD-card");
|
||||||
sdcard_flush();
|
sdcard_flush();
|
||||||
#ifdef SD_LOGGING
|
#ifdef SD_LOGGING
|
||||||
|
Loading…
Reference in New Issue
Block a user