On Wed, 2022-03-30 at 19:33 +0200, Andrew Zaborowski wrote:
p2p_peer_update_existing may be called with a scan_bss struct built
a Probe Request frame so it can't access bss->p2p_probe_resp_info
if peer->bss was built from a Probe Response. Check the source frame
type of the scan_bss struct before updating the Device Address.
This fixes one timing issue that would make the autotest fail often.
So I'm still seeing test_3_go_go_neg_responder and
test_4_go_go_neg_initiator failing, but the other two pass now.
src/p2p.c | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/src/p2p.c b/src/p2p.c
index 4c90efb6..ebd0f62b 100644
@@ -3655,11 +3655,15 @@ static bool p2p_peer_update_existing(struct
* Some property changes may need to be notified here.
- if (peer->device_addr == peer->bss->addr)
- peer->device_addr = bss->addr;
+ if (bss->source_frame == SCAN_BSS_PROBE_RESP)
+ else if (bss->source_frame == SCAN_BSS_PROBE_REQ &&
+ peer->device_addr =
+ peer->device_addr = bss->addr;
peer->bss = bss;