From: Akinobu Mita <akinobu.mita@gmail.com>
To: linux-wireless@vger.kernel.org
Cc: "John W. Linville" <linville@tuxdriver.com>,
Johannes Berg <johannes@sipsolutions.net>,
Joe Jezak <josejx@gentoo.org>, Daniel Drake <dsd@gentoo.org>
Subject: [PATCH] softmac: alloc_ieee80211() NULL check
Date: Sun, 27 May 2007 23:26:31 +0900 [thread overview]
Message-ID: <20070527142631.GA13105@APFDCB5C> (raw)
This patch adds missing NULL check and trims a line longer than 80 columns.
Cc: John W. Linville <linville@tuxdriver.com>
Cc: Johannes Berg <johannes@sipsolutions.net>
Cc: Joe Jezak <josejx@gentoo.org>
Cc: Daniel Drake <dsd@gentoo.org>
Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
---
net/ieee80211/softmac/ieee80211softmac_module.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
Index: 2.6-mm/net/ieee80211/softmac/ieee80211softmac_module.c
===================================================================
--- 2.6-mm.orig/net/ieee80211/softmac/ieee80211softmac_module.c
+++ 2.6-mm/net/ieee80211/softmac/ieee80211softmac_module.c
@@ -33,7 +33,10 @@ struct net_device *alloc_ieee80211softma
struct ieee80211softmac_device *softmac;
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->dev = dev;
softmac->ieee = netdev_priv(dev);
reply other threads:[~2007-05-27 14:34 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20070527142631.GA13105@APFDCB5C \
--to=akinobu.mita@gmail.com \
--cc=dsd@gentoo.org \
--cc=johannes@sipsolutions.net \
--cc=josejx@gentoo.org \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox