From 06d23f2287e1ea1a776953f344c88e96c848776e Mon Sep 17 00:00:00 2001 From: Christian B Date: Fri, 9 Mar 2018 13:38:47 +0100 Subject: [PATCH] Fix build on older kernels * Added a kernel check for older kernels, fix compiling. fixes #76 --- os_dep/linux/ioctl_cfg80211.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/os_dep/linux/ioctl_cfg80211.c b/os_dep/linux/ioctl_cfg80211.c index 8a7e088..17937e7 100644 --- a/os_dep/linux/ioctl_cfg80211.c +++ b/os_dep/linux/ioctl_cfg80211.c @@ -1750,6 +1750,7 @@ static int cfg80211_rtw_get_station(struct wiphy *wiphy, sinfo->filled |= STATION_INFO_BSS_PARAM; +#if defined (LINUX_VERSION_CODE) && (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 20, 0)) if (!psta->no_short_preamble_set) sinfo->bss_param.flags |= STATION_INFO_BSS_PARAM_SHORT_PREAMBLE; @@ -1765,6 +1766,7 @@ static int cfg80211_rtw_get_station(struct wiphy *wiphy, sinfo->bss_param.dtim_period = pwrctl->dtim; sinfo->bss_param.beacon_interval = get_beacon_interval(&cur_network->network); +#endif }