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

Skip to content
Commit e28bb6de authored by Hyundo Moon's avatar Hyundo Moon
Browse files

Fix advertising set slot becoming unusable

When the event 'set random address complete' comes right after removing
the advertising set, the advertising ID becomes unusable from that
moment.

This eventually leads to using all advertising slots, which makes
impossible to create any new advertising set.

This CL fixes the issue by checking existance of a key before accessing
advertising_sets_ with [] operator, preventing unintended creation
of a map entry.

Not only for address rotation complete event, but also this CL adds
checks for all accesses to the map which can cause the same problem.

Bug: 380772123
Bug: 388615378
Test: atest bluetooth_test_gd_unit
Test: Manual, b/380772123#comment15
Flag: com.android.bluetooth.flags.fix_unusable_adv_slot_due_to_map_access
Change-Id: I91b6a6647099e49adefe95f1789f6976e33c7bc9
parent 14e5fd39
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment