mirror of
https://github.com/espressif/esp-nimble.git
synced 2026-08-05 17:47:53 +00:00
fix(nimble): Updating the count parameter when fetching gatt db
This commit is contained in:
@@ -3528,6 +3528,7 @@ int ble_gattc_get_db(uint16_t conn_handle,
|
||||
return BLE_ATT_ERR_ATTR_NOT_FOUND;
|
||||
}
|
||||
if (db) {
|
||||
*count = num;
|
||||
memcpy(result, db, num * sizeof(ble_gattc_db_elem_t)); // Copy data
|
||||
free(db); // Free allocated memory
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user