mac80211: Check rate->idx before rate->count
The drivers are not required to fill in rate->count if rate->idx is set to -1. Hence, we should first check rate->idx before accessing rate->count. Signed-off-by: NHelmut Schaa <helmut.schaa@googlemail.com> Acked-by: NFelix Fietkau <nbd@openwrt.org> Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
Showing
想要评论请 注册 或 登录