Bluetooth: SMP: Fix responding to Pairing Failed PDUs
It makes no sense to respond with Pairing Failed PDU to another Pairing Failed PDU. Jira: ZEP-2620 Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
This commit is contained in:
parent
2450ce4867
commit
bac7367b0a
1 changed files with 4 additions and 1 deletions
|
@ -3432,7 +3432,10 @@ static void bt_smp_recv(struct bt_l2cap_chan *chan, struct net_buf *buf)
|
|||
|
||||
if (!atomic_test_and_clear_bit(&smp->allowed_cmds, hdr->code)) {
|
||||
BT_WARN("Unexpected SMP code 0x%02x", hdr->code);
|
||||
smp_error(smp, BT_SMP_ERR_UNSPECIFIED);
|
||||
/* Don't send error responses to error PDUs */
|
||||
if (hdr->code != BT_SMP_CMD_PAIRING_FAIL) {
|
||||
smp_error(smp, BT_SMP_ERR_UNSPECIFIED);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue