mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-12 09:58:36 +00:00
guard against adhoc_pick_channel returning a NULL channel; this can
happen after a scan cache flush (e.g. in response to ifconfig wlan bssid -)
This commit is contained in:
parent
4bf0267894
commit
63c61408ef
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=183421
@ -1392,9 +1392,12 @@ adhoc_pick_bss(struct ieee80211_scan_state *ss, struct ieee80211vap *vap)
|
||||
*/
|
||||
if (vap->iv_des_chan == IEEE80211_CHAN_ANYC ||
|
||||
IEEE80211_IS_CHAN_RADAR(vap->iv_des_chan)) {
|
||||
chan = ieee80211_ht_adjust_channel(vap->iv_ic,
|
||||
adhoc_pick_channel(ss, 0),
|
||||
vap->iv_flags_ext);
|
||||
struct ieee80211com *ic = vap->iv_ic;
|
||||
|
||||
chan = adhoc_pick_channel(ss, 0);
|
||||
if (chan != NULL)
|
||||
chan = ieee80211_ht_adjust_channel(ic,
|
||||
chan, vap->iv_flags_ext);
|
||||
} else
|
||||
chan = vap->iv_des_chan;
|
||||
if (chan != NULL) {
|
||||
|
Loading…
Reference in New Issue
Block a user