Bluetooth: GATT: fixing unsubscription
If subcription was found within the subscription list, we have check if remains identical subscription from the next node. Otherwise none unsubscription is realized. Change-Id: I38132d7c80575801885b8057902f3d4666b08aea Signed-off-by: Jonathan Gelie <jonathanx.gelie@intel.com>
This commit is contained in:
parent
ce2d74a58a
commit
048a15bcc8
2 changed files with 2 additions and 0 deletions
|
@ -1369,6 +1369,7 @@ int bt_gatt_unsubscribe(struct bt_conn *conn,
|
|||
if (params == tmp) {
|
||||
found = params;
|
||||
sys_slist_remove(&subscriptions, prev, node);
|
||||
continue;
|
||||
} else {
|
||||
prev = node;
|
||||
}
|
||||
|
|
|
@ -1779,6 +1779,7 @@ int bt_gatt_unsubscribe(struct bt_conn *conn,
|
|||
if (params == tmp) {
|
||||
found = true;
|
||||
sys_slist_remove(&subscriptions, prev, node);
|
||||
continue;
|
||||
} else {
|
||||
prev = node;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue