From: Johannes Berg Date: Thu, 24 Apr 2008 12:16:36 +0000 (+0200) Subject: mac80211: don't allow invalid WDS peer addresses X-Git-Tag: v2.6.26-rc1~5^2~35^2~4 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e94e106831403d5028e7bb73c3163951134de1ba;p=linux-2.6 mac80211: don't allow invalid WDS peer addresses Rather than just disallowing the zero address, disallow all invalid ones. Signed-off-by: Johannes Berg Signed-off-by: John W. Linville --- diff --git a/net/mac80211/main.c b/net/mac80211/main.c index e12ffa1728..ab952fff18 100644 --- a/net/mac80211/main.c +++ b/net/mac80211/main.c @@ -255,7 +255,7 @@ static int ieee80211_open(struct net_device *dev) switch (sdata->vif.type) { case IEEE80211_IF_TYPE_WDS: - if (is_zero_ether_addr(sdata->u.wds.remote_addr)) + if (!is_valid_ether_addr(sdata->u.wds.remote_addr)) return -ENOLINK; /* Create STA entry for the WDS peer */