Patchwork Path for fixed channel issue in aircrack-ng suite

login
register
mail settings
Submitter Joker Joker
Date May 25, 2010, 5:07 a.m.
Message ID <AANLkTinAnMwY0ZCetUmUbuhsp3rB360xvlaGM5ifdFHz@mail.gmail.com>
Download mbox | patch
Permalink /patch/102079/
State Not Applicable, archived
Headers show

Comments

Patch

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;
 }