Skip to content

Commit

Permalink
extmod/modbluetooth_nimble: Fix wrong offset used for descriptor flags.
Browse files Browse the repository at this point in the history
  • Loading branch information
jimmo authored and dpgeorge committed Feb 18, 2020
1 parent 66ac2e1 commit cddb90e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion extmod/modbluetooth_nimble.c
Expand Up @@ -508,7 +508,7 @@ int mp_bluetooth_gatts_register_service(mp_obj_bluetooth_uuid_t *service_uuid, m
for (size_t j = 0; j < num_descriptors[i]; ++j) {
descriptors[j].uuid = create_nimble_uuid(descriptor_uuids[descriptor_index]);
descriptors[j].access_cb = characteristic_access_cb;
descriptors[j].att_flags = descriptor_flags[i];
descriptors[j].att_flags = descriptor_flags[descriptor_index];
descriptors[j].min_key_size = 0;
// Unlike characteristic, Nimble doesn't provide an automatic way to remember the handle, so use the arg.
descriptors[j].arg = &handles[handle_index];
Expand Down

0 comments on commit cddb90e

Please sign in to comment.