EIR data uses little endian format, UUID128 values needs to be converted to host order before to use it on SDP library functions. --- src/event.c | 6 +----- 1 files changed, 1 insertions(+), 5 deletions(-) diff --git a/src/event.c b/src/event.c index 12dbca2..87e96dd 100644 --- a/src/event.c +++ b/src/event.c @@ -361,11 +361,7 @@ static int parse_eir_data(struct eir_data *eir, uint8_t *eir_data, service.type = SDP_UUID128; for (i = uuid32_count + uuid16_count; i < total; i++) { - int k; - - for (k = 0; k < 16; k++) - service.value.uuid128.data[k] = uuid128[16 - k - 1]; - + btoh128((uint128_t *) uuid128, &service.value.uuid128); uuid_str = bt_uuid2string(&service); eir->services = g_slist_append(eir->services, uuid_str); uuid128 += 16; -- 1.7.4.1 -- To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html