diff options
author | Jithu Jance <jithu@broadcom.com> | 2012-01-22 17:20:53 +0200 |
---|---|---|
committer | Jouni Malinen <j@w1.fi> | 2012-01-22 17:20:53 +0200 |
commit | 8aebb0e471f2e89e146713ebf9f3e1cbb58e8f52 (patch) | |
tree | e9935a20c1c7ea49169afbe892c6caed8c2cf721 /src/p2p | |
parent | 74590e710f65134522b9a654609ac38d0ce54852 (diff) | |
download | external_wpa_supplicant_8_ti-8aebb0e471f2e89e146713ebf9f3e1cbb58e8f52.zip external_wpa_supplicant_8_ti-8aebb0e471f2e89e146713ebf9f3e1cbb58e8f52.tar.gz external_wpa_supplicant_8_ti-8aebb0e471f2e89e146713ebf9f3e1cbb58e8f52.tar.bz2 |
P2P: Notify upper framework on stopping the p2p_find(SEARCH)
This patch notifies the upper framework that an on-going discovery has
been stopped. This is useful in cases where a p2p_find with a timeout
value initiated by the upper framework has been finished or when the
framework initiated "p2p_find" is stopped by a "p2p_connect".
Signed-hostap: Jithu Jance <jithu@broadcom.com>
Diffstat (limited to 'src/p2p')
-rw-r--r-- | src/p2p/p2p.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/p2p/p2p.c b/src/p2p/p2p.c index e61e133..2fcac0e 100644 --- a/src/p2p/p2p.c +++ b/src/p2p/p2p.c @@ -18,6 +18,7 @@ #include "eloop.h" #include "common/ieee802_11_defs.h" #include "common/ieee802_11_common.h" +#include "common/wpa_ctrl.h" #include "wps/wps_i.h" #include "p2p_i.h" #include "p2p.h" @@ -994,6 +995,8 @@ void p2p_stop_find_for_freq(struct p2p_data *p2p, int freq) wpa_msg(p2p->cfg->msg_ctx, MSG_DEBUG, "P2P: Stopping find"); eloop_cancel_timeout(p2p_find_timeout, p2p, NULL); p2p_clear_timeout(p2p); + if (p2p->state == P2P_SEARCH) + wpa_msg(p2p->cfg->msg_ctx, MSG_INFO, P2P_EVENT_FIND_STOPPED); p2p_set_state(p2p, P2P_IDLE); p2p_free_req_dev_types(p2p); p2p->start_after_scan = P2P_AFTER_SCAN_NOTHING; |