aboutsummaryrefslogtreecommitdiffstats
path: root/wlantest/ctrl.c
diff options
context:
space:
mode:
authorJouni Malinen <jouni.malinen@atheros.com>2011-01-24 12:26:35 (GMT)
committerJouni Malinen <j@w1.fi>2011-01-24 12:34:45 (GMT)
commit0d2e395d74e5d4a77faad08bedb8609209ea0a12 (patch)
tree803ebddc417155ec193f67f294751f209206d793 /wlantest/ctrl.c
parenteb4923fdae82a8d9609762bfc87d3012e9f29414 (diff)
downloadhostap-0d2e395d74e5d4a77faad08bedb8609209ea0a12.zip
hostap-0d2e395d74e5d4a77faad08bedb8609209ea0a12.tar.gz
hostap-0d2e395d74e5d4a77faad08bedb8609209ea0a12.tar.bz2
wlantest: Maintain only a single entry for an active direct link
The TDLS link itself is bidirectional, but there is explicit initiator/responder roles. Remove the other direction of the link if it exists when processing TDLS Setup Confirm to make sure that the link counters are stored for the current TDLS entery. This is also changing the control interface search for TDLS counters to require initiator/responder addresses in the correct order instead of matching entries regardless of the role.
Diffstat (limited to 'wlantest/ctrl.c')
-rw-r--r--wlantest/ctrl.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/wlantest/ctrl.c b/wlantest/ctrl.c
index 11a7dd4..e97448d 100644
--- a/wlantest/ctrl.c
+++ b/wlantest/ctrl.c
@@ -444,8 +444,7 @@ static void ctrl_get_tdls_counter(struct wlantest *wt, int sock, u8 *cmd,
}
dl_list_for_each(tdls, &bss->tdls, struct wlantest_tdls, list) {
- if ((tdls->init == sta && tdls->resp == sta2) ||
- (tdls->init == sta2 && tdls->resp == sta)) {
+ if (tdls->init == sta && tdls->resp == sta2) {
found = 1;
break;
}