mirror of
https://github.com/esphome/esphome.git
synced 2026-09-30 16:30:22 +00:00
Check the cache-clean status in release_services()
The one IDF call in the backend that skipped check_and_log_error_. A failed clean leaves a stale database the next connection could serve as authoritative, with nothing in the log to point at it. (The call fails only at dispatch - stack down - not for an empty cache, so this cannot warn-spam routine teardowns.)
This commit is contained in:
@@ -301,7 +301,9 @@ void BluedroidGattClient::release_services() {
|
||||
// Always set: terminates any in-flight stream on every cache config.
|
||||
this->services_released_ = true;
|
||||
#ifndef CONFIG_BT_GATTC_CACHE_NVS_FLASH
|
||||
esp_ble_gattc_cache_clean(this->remote_bda_);
|
||||
// A failed clean leaves a stale database the next connection could serve
|
||||
// as authoritative; make it visible like every other IDF call here.
|
||||
this->check_and_log_error_("esp_ble_gattc_cache_clean", esp_ble_gattc_cache_clean(this->remote_bda_));
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user