Skip to content

Commit

Permalink
Bluetooth: controller: Avoid deferencing null return value
Browse files Browse the repository at this point in the history
Add assert check to avoid deferencing null return value by
ull_adv_set_get() function.

Fixes #35347.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
  • Loading branch information
cvinayak authored and nashif committed May 19, 2021
1 parent 7d1a959 commit c0a8f38
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions subsys/bluetooth/controller/ll_sw/ull.c
Original file line number Diff line number Diff line change
Expand Up @@ -892,6 +892,8 @@ void ll_rx_dequeue(void)
struct lll_adv_aux *lll_aux;

adv = ull_adv_set_get(rx->handle);
LL_ASSERT(adv);

lll_aux = adv->lll.aux;
if (lll_aux) {
struct ll_adv_aux_set *aux;
Expand Down

0 comments on commit c0a8f38

Please sign in to comment.