From patchwork Tue May 25 05:07:53 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joker Joker X-Patchwork-Id: 102079 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o4P57uio017490 for ; Tue, 25 May 2010 05:07:56 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752990Ab0EYFHz (ORCPT ); Tue, 25 May 2010 01:07:55 -0400 Received: from mail-iw0-f174.google.com ([209.85.214.174]:52233 "EHLO mail-iw0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752572Ab0EYFHy (ORCPT ); Tue, 25 May 2010 01:07:54 -0400 Received: by iwn6 with SMTP id 6so4356206iwn.19 for ; Mon, 24 May 2010 22:07:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:date:message-id :subject:from:to:content-type; bh=C30LBFh6Xb49q0Eqbe7FgqK3BNzHke6q/Zv2hUKkn4k=; b=ku2jYEMind6yPh3Wx92ED7aEErOpt0YyFm4/F+fDMqgoPoRgHRm3e7OlQ7DakFS/cO horCN6WzwPam+cLRO1FCRxiNMtXLBQbe7E8KPkp+h8MTPi6KIAH4Jeiu2XB06SylhjF5 LHVATAelslcnF6nSoQ/RYAaNUPN0HuiE8b7gI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=O3eKHDPmKo5EROYuGO2zg/u5Gv5u8Ff7e67sTsDjIJwx1u7jKX2PLneQlaPCnMog82 BB4GnwXjLUxYGeYCTisoJb1qLGUQEoZOOLl9mmLQinFPd8qRcB4dErGn3J43JOePAwbk VdvV8aSDqxSC+1E4j4ukqJunPrXtM87W90PF8= MIME-Version: 1.0 Received: by 10.231.158.132 with SMTP id f4mr5547444ibx.52.1274764073503; Mon, 24 May 2010 22:07:53 -0700 (PDT) Received: by 10.231.11.137 with HTTP; Mon, 24 May 2010 22:07:53 -0700 (PDT) Date: Tue, 25 May 2010 01:07:53 -0400 Message-ID: Subject: Path for fixed channel issue in aircrack-ng suite From: Joker Joker To: linux-wireless@vger.kernel.org Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Tue, 25 May 2010 05:07:56 +0000 (UTC) diff --git a/net/wireless/chan.c b/net/wireless/chan.c index d92d088..93f6c19 100644 --- a/net/wireless/chan.c +++ b/net/wireless/chan.c @@ -48,6 +48,7 @@ int cfg80211_set_freq(struct cfg80211_registered_device *rdev, enum nl80211_channel_type channel_type) { struct ieee80211_channel *chan; + struct wireless_dev *old_wdev = wdev; int result; if (wdev->iftype == NL80211_IFTYPE_MONITOR) @@ -73,8 +74,8 @@ int cfg80211_set_freq(struct cfg80211_registered_device *rdev, if (result) return result; - if (wdev) - wdev->channel = chan; + wdev = old_wdev; + wdev->channel = chan; return 0; }