Cumulative patch from commit 594516b4c28a94ca686b17f1e463dfd6712b75a7
594516b Use monotonic clock for relative time for eloop if available
461e3eb Fix and work around some MinGW compilation issues
81cbc04 Fix compiler warning for OpenSSL without HAVE_OCSP
68d628a hostapd: Fix interface enabling/disabling and DFS
1cba9be STA: Cancel sched_scan while initiating wps_reassoc
215a02f Add Wi-Fi Direct to the build configuration example
ca9c14f dbus_new: Add documentation for D-Bus TDLS methods
6fc4848 P2P: Short scan wait to speed up the group re-invocation
93a06fe Fix QoS Map Configure frame use
Change-Id: Id76002ca7fa742b6533e7e592ffd3867886dc50e
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
diff --git a/wpa_supplicant/events.c b/wpa_supplicant/events.c
index 31c5baa..ed8cd23 100644
--- a/wpa_supplicant/events.c
+++ b/wpa_supplicant/events.c
@@ -1353,10 +1353,12 @@
if (wpas_p2p_scan_no_go_seen(wpa_s) == 1)
return 0;
- if (wpa_s->p2p_in_provisioning) {
+ if (wpa_s->p2p_in_provisioning ||
+ wpa_s->show_group_started) {
/*
* Use shorter wait during P2P Provisioning
- * state to speed up group formation.
+ * state and during P2P join-a-group operation
+ * to speed up group formation.
*/
timeout_sec = 0;
timeout_usec = 250000;
@@ -3077,12 +3079,15 @@
if (data->rx_action.category == WLAN_ACTION_QOS &&
data->rx_action.len >= 1 &&
data->rx_action.data[0] == QOS_QOS_MAP_CONFIG) {
+ const u8 *pos = data->rx_action.data + 1;
+ size_t len = data->rx_action.len - 1;
wpa_dbg(wpa_s, MSG_DEBUG, "Interworking: Received QoS Map Configure frame from "
MACSTR, MAC2STR(data->rx_action.sa));
- if (os_memcmp(data->rx_action.sa, wpa_s->bssid, ETH_ALEN)
- == 0)
- wpas_qos_map_set(wpa_s, data->rx_action.data + 1,
- data->rx_action.len - 1);
+ if (os_memcmp(data->rx_action.sa, wpa_s->bssid,
+ ETH_ALEN) == 0 &&
+ len > 2 && pos[0] == WLAN_EID_QOS_MAP_SET &&
+ pos[1] <= len - 2 && pos[1] >= 16)
+ wpas_qos_map_set(wpa_s, pos + 2, pos[1]);
break;
}
#endif /* CONFIG_INTERWORKING */