Search Linux Wireless

[PATCH] iw: fix attribute size mismatch

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

 



NL80211_ATTR_MAX_AP_ASSOC_STA gets packed as u32 in the kernel.
Change the receiving side to match this, or it will be wrong
on big-endian.

Signed-off-by: Koen Vandeputte <koen.vandeputte@xxxxxxxxxxxx>
---
 info.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/info.c b/info.c
index 364f9b3..4c5f463 100644
--- a/info.c
+++ b/info.c
@@ -879,7 +879,7 @@ broken_combination:
 
 	if (tb_msg[NL80211_ATTR_MAX_AP_ASSOC_STA])
 		printf("\tMaximum associated stations in AP mode: %u\n",
-		       nla_get_u16(tb_msg[NL80211_ATTR_MAX_AP_ASSOC_STA]));
+		       nla_get_u32(tb_msg[NL80211_ATTR_MAX_AP_ASSOC_STA]));
 
 	return NL_SKIP;
 }
-- 
2.34.1




[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