public inbox for linux-wireless@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] mac80211: fix register_hw error path
@ 2009-08-19 17:45 Johannes Berg
  0 siblings, 0 replies; only message in thread
From: Johannes Berg @ 2009-08-19 17:45 UTC (permalink / raw)
  To: John Linville; +Cc: linux-wireless

"cfg80211: fix alignment problem in scan request"
introduced a bug into the error path, because now
we allocate the entire scan request and not just
the channel list (the channel list is allocated
together with the scan request) -- on errors we
thus also need to free the entire scan request.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
---
 net/mac80211/main.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- wireless-testing.orig/net/mac80211/main.c	2009-08-19 19:44:18.000000000 +0200
+++ wireless-testing/net/mac80211/main.c	2009-08-19 19:44:20.000000000 +0200
@@ -930,7 +930,7 @@ int ieee80211_register_hw(struct ieee802
  fail_workqueue:
 	wiphy_unregister(local->hw.wiphy);
  fail_wiphy_register:
-	kfree(local->int_scan_req->channels);
+	kfree(local->int_scan_req);
 	return result;
 }
 EXPORT_SYMBOL(ieee80211_register_hw);



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2009-08-19 17:46 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-08-19 17:45 [PATCH] mac80211: fix register_hw error path Johannes Berg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox