Commit 00fc90c886220efe8b634d3f2a04713fcebbe2c0

Authored by John W. Linville
1 parent a6e492b9b5

minstrel_ht: remove unnecessary NULL check in minstrel_ht_update_caps

If sta is NULL, we will have problems long before we get here...

Reported-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Cc: Felix Fietkau <nbd@openwrt.org>

Showing 1 changed file with 1 additions and 1 deletions Side-by-side Diff

net/mac80211/rc80211_minstrel_ht.c
... ... @@ -636,7 +636,7 @@
636 636 int i;
637 637  
638 638 /* fall back to the old minstrel for legacy stations */
639   - if (sta && !sta->ht_cap.ht_supported) {
  639 + if (!sta->ht_cap.ht_supported) {
640 640 msp->is_ht = false;
641 641 memset(&msp->legacy, 0, sizeof(msp->legacy));
642 642 msp->legacy.r = msp->ratelist;