* [PATCH] rtl8180: avoid potential NULL deref in rtl8180_beacon_work
@ 2010-08-05 17:46 John W. Linville
0 siblings, 0 replies; only message in thread
From: John W. Linville @ 2010-08-05 17:46 UTC (permalink / raw)
To: linux-wireless; +Cc: John W. Linville
ieee80211_beacon_get can return NULL...
Signed-off-by: John W. Linville <linville@tuxdriver.com>
---
drivers/net/wireless/rtl818x/rtl8180_dev.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/drivers/net/wireless/rtl818x/rtl8180_dev.c b/drivers/net/wireless/rtl818x/rtl8180_dev.c
index 1d81785..b50c39a 100644
--- a/drivers/net/wireless/rtl818x/rtl8180_dev.c
+++ b/drivers/net/wireless/rtl818x/rtl8180_dev.c
@@ -695,6 +695,8 @@ static void rtl8180_beacon_work(struct work_struct *work)
/* grab a fresh beacon */
skb = ieee80211_beacon_get(dev, vif);
+ if (!skb)
+ goto resched;
/*
* update beacon timestamp w/ TSF value
--
1.7.2
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2010-08-05 18:14 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-08-05 17:46 [PATCH] rtl8180: avoid potential NULL deref in rtl8180_beacon_work John W. Linville
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).