Commit ef7ab235 authored by Akinobu Mita's avatar Akinobu Mita Committed by John W. Linville

[PATCH] softmac: alloc_ieee80211() NULL check

This patch adds missing NULL check and trims a line longer than 80 columns.

Cc: Johannes Berg <johannes@sipsolutions.net>
Cc: Joe Jezak <josejx@gentoo.org>
Cc: Daniel Drake <dsd@gentoo.org>
Signed-off-by: default avatarAkinobu Mita <akinobu.mita@gmail.com>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent a76193df
...@@ -33,7 +33,10 @@ struct net_device *alloc_ieee80211softmac(int sizeof_priv) ...@@ -33,7 +33,10 @@ struct net_device *alloc_ieee80211softmac(int sizeof_priv)
struct ieee80211softmac_device *softmac; struct ieee80211softmac_device *softmac;
struct net_device *dev; struct net_device *dev;
dev = alloc_ieee80211(sizeof(struct ieee80211softmac_device) + sizeof_priv); dev = alloc_ieee80211(sizeof(*softmac) + sizeof_priv);
if (!dev)
return NULL;
softmac = ieee80211_priv(dev); softmac = ieee80211_priv(dev);
softmac->dev = dev; softmac->dev = dev;
softmac->ieee = netdev_priv(dev); softmac->ieee = netdev_priv(dev);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment