Diff between cbe6a5b6ff93aae3d74cb8137d351d3bc9b1ff2e and d65ee066a1187cd868843111253c0462092f19a0
Changed Files
| File | Additions | Deletions | Status |
| attrib/gatt.c | +1 | -1 | modified |
Full Patch
diff --git a/attrib/gatt.c b/attrib/gatt.c
index b9c2bbb..6f9a11d 100644
--- a/attrib/gatt.c
+++ b/attrib/gatt.c
@@ -303,7 +303,7 @@ static void char_discovered_cb(guint8 status, const guint8 *ipdu, guint16 iplen,
att_data_list_free(list);
err = 0;
- if (last != 0) {
+ if (last != 0 && (last + 1 < dc->end)) {
buf = g_attrib_get_buffer(dc->attrib, &buflen);
bt_uuid16_create(&uuid, GATT_CHARAC_UUID);