Commit 973934c
Bluetooth: Host: Fix crash on bt_disable() with limited advertising
When limited advertising is enabled there is pending deleyable work
for timing it out. If in such case struct bt_le_ext_adv is cleared by
memset system will crash on next tick.
Fix this by ensuring work is cancelled before clearing struct
bt_le_ext_adv. Using bt_le_ext_adv_foreach() ensures that this will
be correctly handled with and without extended advertising enabled.
Signed-off-by: Szymon Janc <[email protected]>1 parent 45a4f38 commit 973934c
1 file changed
+8
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
| 37 | + | |
37 | 38 | | |
38 | 39 | | |
39 | 40 | | |
| |||
247 | 248 | | |
248 | 249 | | |
249 | 250 | | |
250 | | - | |
| 251 | + | |
251 | 252 | | |
252 | | - | |
253 | | - | |
254 | | - | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
255 | 256 | | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
256 | 260 | | |
257 | 261 | | |
258 | 262 | | |
| |||
0 commit comments