Diff between 184b608997ab965b21d1b0623e3bb94326610145 and 816d40fc5ea18a363ba342c7597e6f3f80d5eb32

Changed Files

File Additions Deletions Status
src/shared/gatt-db.c +4 -1 modified

Full Patch

diff --git a/src/shared/gatt-db.c b/src/shared/gatt-db.c
index cc8e494..af1cde9 100644
--- a/src/shared/gatt-db.c
+++ b/src/shared/gatt-db.c
@@ -829,7 +829,10 @@ struct gatt_db_attribute *gatt_db_get_attribute(struct gatt_db *db,
 
 const bt_uuid_t *gatt_db_attribute_get_type(struct gatt_db_attribute *attrib)
 {
-	return NULL;
+	if (!attrib)
+		return NULL;
+
+	return &attrib->uuid;
 }
 
 uint16_t gatt_db_attribute_get_handle(struct gatt_db_attribute *attrib)