diff options
author | Jithu Jance <jithu@broadcom.com> | 2014-08-19 14:19:38 -0700 |
---|---|---|
committer | Dmitry Shmidt <dimitrysh@google.com> | 2014-08-19 14:19:38 -0700 |
commit | 1d57ba2e974d60c4b36b65c9d58f6ec7cebad0aa (patch) | |
tree | a78f13aac42f57467adaf2e08c0f750857e37201 /src/p2p/p2p.c | |
parent | 5c879ee8a1def48a71e0929d378c0912ef63bb3f (diff) | |
download | wpa_supplicant_8-1d57ba2e974d60c4b36b65c9d58f6ec7cebad0aa.tar.gz |
P2P: Clear the discovery state incase of deffered GO Neg response
Bug: 17027752
Change-Id: I7d16080864264b838169f7b477598353c5d61d37
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Diffstat (limited to 'src/p2p/p2p.c')
-rw-r--r-- | src/p2p/p2p.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/p2p/p2p.c b/src/p2p/p2p.c index 565cbdbd..3a5486b9 100644 --- a/src/p2p/p2p.c +++ b/src/p2p/p2p.c @@ -3034,8 +3034,17 @@ static void p2p_go_neg_resp_failure_cb(struct p2p_data *p2p, int success, struct p2p_device *dev; dev = p2p_get_device(p2p, addr); if (dev && - dev->status == P2P_SC_FAIL_INFO_CURRENTLY_UNAVAILABLE) + dev->status == P2P_SC_FAIL_INFO_CURRENTLY_UNAVAILABLE) { dev->flags |= P2P_DEV_PEER_WAITING_RESPONSE; + if ((p2p->state == P2P_SEARCH) || + (p2p->state == P2P_LISTEN_ONLY)) { + /* Clear our search state or Listen state since + * now peer is awaiting response from our side. + */ + p2p_dbg(p2p, "Clear the P2P discovery state"); + p2p_stop_find(p2p); + } + } } } |