]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
P2P: Send p2p_stop_find event on failure to start pending p2p_find
authorDeepthi Gowri <deepthi@codeaurora.org>
Fri, 8 Feb 2013 09:37:07 +0000 (11:37 +0200)
committerJouni Malinen <j@w1.fi>
Fri, 8 Feb 2013 09:37:07 +0000 (11:37 +0200)
When pending p2p_find fails we need to send p2p_stop_find event to
indicate the previous p2p_find command has been processed.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>

src/p2p/p2p.c

index 43f8673db18ddf5dc762459505bdf2695b6814bb..55a95b5710b26e08a787f9de68ab3afbfde2bc40 100644 (file)
@@ -1066,8 +1066,10 @@ int p2p_other_scan_completed(struct p2p_data *p2p)
                "now that previous scan was completed");
        if (p2p_find(p2p, p2p->last_p2p_find_timeout, p2p->find_type,
                     p2p->num_req_dev_types, p2p->req_dev_types,
-                    p2p->find_dev_id, p2p->search_delay) < 0)
+                    p2p->find_dev_id, p2p->search_delay) < 0) {
+               wpa_msg(p2p->cfg->msg_ctx, MSG_INFO, P2P_EVENT_FIND_STOPPED);
                return 0;
+       }
        return 1;
 }