Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f4dc23ee authored by Jakub Pawlowski's avatar Jakub Pawlowski Committed by Andre Eisenbach
Browse files

HOGP: Clear pending operations for a given device on disconnect

If there are any GATT operations interrupted by a disconnect, mark the
device as no longer executing. Otherwise we'll stil receive data from
the device, but we'll be unable to send any HID commands to it.

Bug: 29184976
Change-Id: I489f41c970abad0ff1145005d3250beafa83d27e
parent ac84df6e
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -131,6 +131,8 @@ static bool rm_op_by_conn_id(void *data, void *context) {
static void gatt_op_queue_clean(UINT16 conn_id) {
    if (gatt_op_queue)
        list_foreach(gatt_op_queue, rm_op_by_conn_id, &conn_id);

    mark_as_not_executing(conn_id);
}

static bool find_op_by_conn_id(void *data, void *context) {