Skip to content
Commit 5f59b35b authored by Erik Sandgren's avatar Erik Sandgren Committed by Anas Nashif
Browse files

Bluetooth: Host: Fix issue where uninitialized value was used



This change makes sure that when a call to `bt_id_set_scan_own_addr` is
sucessful, i.e., the return value is 0, the `own_addr_type` will
be set by the `bt_id_set_scan_own_addr`.

Not setting the `own_addr_type` in a successful call to
`bt_id_set_scan_own_addr` causes, for example,
the `start_le_scan_ext` method in `scan.c` to use an
uninitialized `own_addr_type`.

Eventually this results in an unexpected failure further down in
`start_le_scan_ext`, when sending HCI command to controller with
an uninitialized `own_addr_type`.

Signed-off-by: default avatarErik Sandgren <erik.sandgren@nordicsemi.no>
parent a5558380
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment