浏览代码

wireless: Use macro instead of number

Use IEEE80211_MIN_ACTION_SIZE macro for robust management frame check.

Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Masashi Honma 9 年之前
父节点
当前提交
e98e915e11
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      include/linux/ieee80211.h

+ 1 - 1
include/linux/ieee80211.h

@@ -2464,7 +2464,7 @@ static inline bool _ieee80211_is_robust_mgmt_frame(struct ieee80211_hdr *hdr)
  */
 static inline bool ieee80211_is_robust_mgmt_frame(struct sk_buff *skb)
 {
-	if (skb->len < 25)
+	if (skb->len < IEEE80211_MIN_ACTION_SIZE)
 		return false;
 	return _ieee80211_is_robust_mgmt_frame((void *)skb->data);
 }