* [PATCH] cfg80211: fix crash in cfg80211_set_freq()
@ 2010-05-15 13:46 Felix Fietkau
0 siblings, 0 replies; only message in thread
From: Felix Fietkau @ 2010-05-15 13:46 UTC (permalink / raw)
To: linux-wireless; +Cc: linville, johannes
Since wdev can be NULL, check it before dereferencing it
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
---
net/wireless/chan.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/net/wireless/chan.c b/net/wireless/chan.c
index d92d088..b01a6f6 100644
--- a/net/wireless/chan.c
+++ b/net/wireless/chan.c
@@ -50,7 +50,7 @@ int cfg80211_set_freq(struct cfg80211_registered_device *rdev,
struct ieee80211_channel *chan;
int result;
- if (wdev->iftype == NL80211_IFTYPE_MONITOR)
+ if (wdev && wdev->iftype == NL80211_IFTYPE_MONITOR)
wdev = NULL;
if (wdev) {
--
1.6.4.2
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2010-05-15 13:46 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-05-15 13:46 [PATCH] cfg80211: fix crash in cfg80211_set_freq() Felix Fietkau
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox