Surface the node-capacity guard in component status and log sync register failures

This commit is contained in:
J. Nick Koston
2026-08-12 18:38:04 -05:00
parent f5debdad32
commit e158205e4c
2 changed files with 3 additions and 1 deletions
+2 -1
View File
@@ -145,6 +145,7 @@ void BLEClient::register_gatt_node(BLEClientNode *node) {
// push_back past capacity is a silent no-op; an undersized slot count
// must be loud at boot, not an unresolvable node at runtime.
ESP_LOGE(TAG, "[%s] Node capacity exceeded; node dropped", this->address_str());
this->status_set_error(LOG_STR("node capacity exceeded"));
return;
}
this->gatt_nodes_.push_back(node);
@@ -324,7 +325,7 @@ int BLEClient::notify_characteristic(uint16_t handle, bool enable) {
esp_err_t err = this->register_for_notify(handle);
if (err == ESP_OK)
this->pending_gatt_regs_[this->pending_gatt_reg_count_++] = handle;
return err;
return this->check_and_log_error_("register_for_notify", err);
}
return this->check_and_log_error_("esp_ble_gattc_unregister_for_notify",
esp_ble_gattc_unregister_for_notify(this->gattc_if_, this->remote_bda_, handle));
@@ -15,6 +15,7 @@ void BLEClient::register_ble_node(BLEClientNode *node) {
// push_back past capacity is a silent no-op; an undersized slot count
// must be loud at boot, not an unresolvable node at runtime.
ESP_LOGE(TAG, "[%s] Node capacity exceeded; node dropped", this->address_str_);
this->status_set_error(LOG_STR("node capacity exceeded"));
return;
}
this->nodes_.push_back(node);