mac80211: avoid NULL ptr deref when finding max_rates in PID and minstrel
commit56009774704b0cf6052466b82300b4cdd5ccc855
authorJohn W. Linville <linville@tuxdriver.com>
Tue, 5 May 2009 19:18:26 +0000 (5 15:18 -0400)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 15 Jun 2009 16:40:12 +0000 (15 09:40 -0700)
treea151b535c0233215eb6dff607f7de6c3f14ebea5
parent94a9ef2fbeed9360a2036fcc79873dcf9ab7acf3
mac80211: avoid NULL ptr deref when finding max_rates in PID and minstrel

commit 621ad7c96aa138cfeab53cd4debc5a4e08b2189b upstream.

"There is another problem with this piece of code. The sband will be NULL
after second iteration on single band device and cause null pointer
dereference. Everything is working with dual band card. Sorry, but i
don't know how to explain this clearly in English. I have looked on the
second patch for pid algorithm and found similar bug."

Reported-by: Karol Szuster <qflon@o2.pl>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
net/mac80211/rc80211_minstrel.c
net/mac80211/rc80211_pid_algo.c