]> git.ipfire.org Git - thirdparty/hostap.git/commit
P2P: Fix scan_res_handler setting for p2p_scan
authorJouni Malinen <jouni@qca.qualcomm.com>
Wed, 6 Jun 2012 14:07:46 +0000 (17:07 +0300)
committerJouni Malinen <j@w1.fi>
Wed, 6 Jun 2012 14:07:46 +0000 (17:07 +0300)
commit5b3763336466f2c55611437cb924aeee45f7203e
tree080df75d41dfa0a94d9d34d57cb3e22d5d9cf02c
parent792c8877c3e9558a6def558c6d35833a00571683
P2P: Fix scan_res_handler setting for p2p_scan

The previous version set scan_res_handler unconditionally and then
cleared it if scan request failed. This can result in incorrect clearing
of the handler to NULL for a previously started scan that has not yet
completed. This can make p2p_find command fail to use the
start-after-scan-completion mechanism in some cases. Fix this by setting
scan_res_handler properly after having verified that the driver command
for starting the scan was successful.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
intended-for: hostap-1
wpa_supplicant/p2p_supplicant.c