mesh: fix check for appkey_index within currently supported range

This commit is contained in:
Matthias Ringwald 2019-06-07 10:40:24 +02:00
parent 81dc2fe64a
commit 51f4adc9f4

View File

@ -354,7 +354,7 @@ typedef struct {
#define MESH_APPKEY_INDEX_MAX (16)
void mesh_store_app_key(uint16_t netkey_index, uint16_t appkey_index, uint8_t aid, const uint8_t * application_key){
if (application_key >= MESH_APPKEY_INDEX_MAX){
if (appkey_index >= MESH_APPKEY_INDEX_MAX){
printf("Warning: AppKey with AppKey Index %x (>= %u) are not persisted\n", appkey_index, MESH_APPKEY_INDEX_MAX);
}
mesh_persistent_app_key_t data;