Skip to content
Commit a3e89e84 authored by François Delawarde's avatar François Delawarde Committed by Johan Hedberg
Browse files

bluetooth: host: Fix simultaneous pairings getting the same keys slot



Fix an issue where a slot in the key pool was considered free when
either the address was cleared or no keys were written in the entry
(enc_size == 0). This caused a problem with simultaneous pairing
attempts that would be assigned the same entry.

This patch makes it so a a slot is considered free even when keys are
not yet present in the entry, and makes sure the address is cleared in
case of pairing failure or timeout so to mark the slot as free.

Signed-off-by: default avatarFrançois Delawarde <fnde@oticon.com>
parent 171a9fa1
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment