Skip to content

Commit 8b36322

Browse files
committed
fix(nimble): Fix unused variable warnings
1 parent 7898ac5 commit 8b36322

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

libraries/BLE/src/BLEDevice.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,7 @@ String BLEDevice::getValue(BLEAddress bdAddress, BLEUUID serviceUUID, BLEUUID ch
236236
*/
237237
void BLEDevice::init(String deviceName) {
238238
if (!initialized) {
239-
esp_err_t errRc = ESP_OK;
239+
[[maybe_unused]] esp_err_t errRc = ESP_OK;
240240
#if defined(ARDUINO_ARCH_ESP32) && !defined(CONFIG_NIMBLE_ENABLED)
241241
if (!btStart()) {
242242
errRc = ESP_FAIL;

libraries/BLE/src/BLEServer.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -537,7 +537,7 @@ void BLEServerCallbacks::onDisconnect(BLEServer *pServer, esp_ble_gatts_cb_param
537537
} // onDisconnect
538538

539539
void BLEServerCallbacks::onMtuChanged(BLEServer *pServer, esp_ble_gatts_cb_param_t *param) {
540-
uint16_t mtu = param->mtu.mtu;
540+
[[maybe_unused]] uint16_t mtu = param->mtu.mtu;
541541
log_d("BLEServerCallbacks", ">> onMtuChanged(): Default");
542542
log_d("BLEServerCallbacks", "Device: %s MTU: %d", BLEDevice::toString().c_str(), mtu);
543543
log_d("BLEServerCallbacks", "<< onMtuChanged()");

0 commit comments

Comments
 (0)