ble_store_config_cccds
referenced even with CCCD persistence disabled (IDFGH-12372)
#13403
Closed
3 tasks done
Labels
Resolution: Done
Issue is done internally
Status: Done
Issue is done internally
Type: Bug
bugs in IDF
Answers checklist.
IDF version.
v5.1.2
Espressif SoC revision.
ESP32
Operating System used.
Windows
How did you build your project?
VS Code IDE
If you are using Windows, please specify command line type.
PowerShell
Development Kit.
Custom Board
Power Supply used.
USB
What is the expected behavior?
Esp-Idf to compile with
CONFIG_BT_NIMBLE_MAX_CCCDS=0
What is the actual behavior?
Compilation fails, since
ble_store_config_cccds
is referenced even when it is undefined.Steps to reproduce.
CONFIG_BT_NIMBLE_MAX_CCCDS
to0
to disable CCCD persistence with Esp-Idf v5.1.2 or newer.Debug Logs.
More Information.
As of commit b85d99d, NimBLE better supports setting
CONFIG_BT_NIMBLE_MAX_CCCDS
to0
to disable CCCD persistence. This is desirable in some circumstances, e.g. see this previous issue where another person uses this configuration value. When this configuration is set, newer versions of NimBLE do not define theble_store_config_cccds
array, since it is not used by the implementation. Unfortunately, the Esp-Idf implementation of CCCD persistence always references theble_store_config_cccds
array inble_store_config_conf.c
andble_store_nvs.c
. As a result, Esp-Idf v5.1.2 will fail to compile ifCONFIG_BT_NIMBLE_MAX_CCCDS
is set to0
. Checks like#if MYNEWT_VAL(BLE_STORE_MAX_CCCDS)
should be added around references to this array to ensure that it is not referenced while undefined.The text was updated successfully, but these errors were encountered: