aboutsummaryrefslogtreecommitdiffstats
path: root/wpa_supplicant/offchannel.c
diff options
context:
space:
mode:
authorWei-Jen Lin <jenlin@qca.qualcomm.com>2013-07-31 20:22:04 (GMT)
committerJouni Malinen <j@w1.fi>2013-07-31 20:22:04 (GMT)
commita2ea8d64d1caa6b5df9bc06cbfa41a3f70210f77 (patch)
treedb8d2b07ecfbb8ec8c26e6edc6c7c819e51f6dd3 /wpa_supplicant/offchannel.c
parentcbf41ca79646857733273d6edf6b583c9b0e2abe (diff)
downloadhostap-a2ea8d64d1caa6b5df9bc06cbfa41a3f70210f77.zip
hostap-a2ea8d64d1caa6b5df9bc06cbfa41a3f70210f77.tar.gz
hostap-a2ea8d64d1caa6b5df9bc06cbfa41a3f70210f77.tar.bz2
P2P: Fix invalid remain-on-channel duration for frame TX
cfg80211 does not allow the zero duration of remain-on-channel. Instead, use 20 ms as default waiting time when remain-on-channel is used to schedule offchannel transmission that does not expect a response. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
Diffstat (limited to 'wpa_supplicant/offchannel.c')
-rw-r--r--wpa_supplicant/offchannel.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/wpa_supplicant/offchannel.c b/wpa_supplicant/offchannel.c
index 856eca7..d94407c 100644
--- a/wpa_supplicant/offchannel.c
+++ b/wpa_supplicant/offchannel.c
@@ -285,6 +285,8 @@ int offchannel_send_action(struct wpa_supplicant *wpa_s, unsigned int freq,
"channel");
if (wait_time > wpa_s->max_remain_on_chan)
wait_time = wpa_s->max_remain_on_chan;
+ else if (wait_time == 0)
+ wait_time = 20;
if (wpa_drv_remain_on_channel(wpa_s, freq, wait_time) < 0) {
wpa_printf(MSG_DEBUG, "Off-channel: Failed to request driver "
"to remain on channel (%u MHz) for Action "