Search Linux Wireless

[PATCH] iw: use correct type in policy check for mesh

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



NL80211_STA_INFO_CONNECTED_TO_AS and NL80211_STA_INFO_CONNECTED_TO_GATE
are defined as u8 in kernel, but were checked against NLA_FLAG.

This fixes:

root@openwrt:~# iw dev wlan0-mesh station
failed to parse nested attributes!
failed to parse nested attributes!
failed to parse nested attributes!

Reported-by: Marc Rantanen <marc@xxxxxxxxxxx>
Tested-by: Marc Rantanen <marc@xxxxxxxxxxx>
Signed-off-by: Markus Theil <markus.theil@xxxxxxxxxxxxx>
---
 station.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/station.c b/station.c
index b2c5b9c..bddea51 100644
--- a/station.c
+++ b/station.c
@@ -329,8 +329,8 @@ static int print_sta_handler(struct nl_msg *msg, void *arg)
 		[NL80211_STA_INFO_ACK_SIGNAL] = {.type = NLA_U8 },
 		[NL80211_STA_INFO_ACK_SIGNAL_AVG] = { .type = NLA_U8 },
 		[NL80211_STA_INFO_AIRTIME_LINK_METRIC] = { .type = NLA_U32 },
-		[NL80211_STA_INFO_CONNECTED_TO_AS] = { .type = NLA_FLAG },
-		[NL80211_STA_INFO_CONNECTED_TO_GATE] = { .type = NLA_FLAG },
+		[NL80211_STA_INFO_CONNECTED_TO_AS] = { .type = NLA_U8 },
+		[NL80211_STA_INFO_CONNECTED_TO_GATE] = { .type = NLA_U8 },
 	};
 	char *chain;
 	struct timeval now;
-- 
2.29.2




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux