att_server: fix lookup for Client Characteristic Configuration in services with multiple Characteristics

This commit is contained in:
Milanka Ringwald 2018-05-15 16:00:02 +02:00
parent c7e2c1a542
commit b58c6eb905
2 changed files with 3 additions and 2 deletions

View File

@ -17,6 +17,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
- SM: Fix LE Secure Connection pairing in Central role
- le_device_db_tlv: fix seq nr management
- SM: improve le_device_db lookup and storing of IRK
- GATT Server: fix lookup for Client Characteristic Configuration in services with multiple Characteristics
## Changes April 2018

View File

@ -1240,7 +1240,7 @@ uint16_t gatt_server_get_client_configuration_handle_for_characteristic_with_uui
if (characteristic_found) break;
continue;
}
if (att_iterator_match_uuid16(&it, GATT_CLIENT_CHARACTERISTICS_CONFIGURATION)){
if (characteristic_found && att_iterator_match_uuid16(&it, GATT_CLIENT_CHARACTERISTICS_CONFIGURATION)){
return it.handle;
}
}
@ -1319,7 +1319,7 @@ uint16_t gatt_server_get_client_configuration_handle_for_characteristic_with_uui
if (characteristic_found) break;
continue;
}
if (att_iterator_match_uuid16(&it, GATT_CLIENT_CHARACTERISTICS_CONFIGURATION)){
if (characteristic_found && att_iterator_match_uuid16(&it, GATT_CLIENT_CHARACTERISTICS_CONFIGURATION)){
return it.handle;
}
}