aboutsummaryrefslogtreecommitdiffstats
path: root/wlantest
diff options
context:
space:
mode:
authorJouni Malinen <jouni.malinen@atheros.com>2010-12-21 12:48:03 +0200
committerJouni Malinen <j@w1.fi>2010-12-21 12:48:03 +0200
commit880a97dc5dc11423ec8874387f2818153cbeddf8 (patch)
tree90e2f007a43f9da7a3e6a71172e35027b13928d2 /wlantest
parentd19f5fc881916214771f5394dbc884fc0f35a9b7 (diff)
downloadexternal_wpa_supplicant_8_ti-880a97dc5dc11423ec8874387f2818153cbeddf8.zip
external_wpa_supplicant_8_ti-880a97dc5dc11423ec8874387f2818153cbeddf8.tar.gz
external_wpa_supplicant_8_ti-880a97dc5dc11423ec8874387f2818153cbeddf8.tar.bz2
wlantest: Fix management frame injection
The TDLS special case was supposed to apply to only Data frames.
Diffstat (limited to 'wlantest')
-rw-r--r--wlantest/inject.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/wlantest/inject.c b/wlantest/inject.c
index 51990e4..3defdf7 100644
--- a/wlantest/inject.c
+++ b/wlantest/inject.c
@@ -216,7 +216,8 @@ static int wlantest_inject_prot(struct wlantest *wt, struct wlantest_bss *bss,
hdrlen = 24;
fc = le_to_host16(hdr->frame_control);
- if ((fc & (WLAN_FC_TODS | WLAN_FC_FROMDS)) == 0) {
+ if (WLAN_FC_GET_TYPE(fc) == WLAN_FC_TYPE_DATA &&
+ (fc & (WLAN_FC_TODS | WLAN_FC_FROMDS)) == 0) {
struct wlantest_sta *sta2;
bss = bss_get(wt, hdr->addr3);
if (bss == NULL)