diff --git a/src/scan.h b/src/scan.h index 934d22c8..6c56f7f4 100644 --- a/src/scan.h +++ b/src/scan.h @@ -41,7 +41,6 @@ typedef void (*scan_freq_set_func_t)(uint32_t freq, void *userdata); struct scan_freq_set; struct ie_rsn_info; -enum ie_bss_capability; struct scan_bss { uint8_t addr[6]; diff --git a/src/station.c b/src/station.c index cdb1d738..f1a9efd7 100644 --- a/src/station.c +++ b/src/station.c @@ -264,6 +264,11 @@ static struct network *station_add_seen_bss(struct station *station, memcpy(ssid, bss->ssid, bss->ssid_len); ssid[bss->ssid_len] = '\0'; + if (!(bss->capability & IE_BSS_CAP_ESS)) { + l_debug("Ignoring non-ESS BSS \"%s\"", ssid); + return NULL; + } + memset(&info, 0, sizeof(info)); r = scan_bss_get_rsn_info(bss, &info); if (r < 0) {