cfg80211: fix refcount leak
authorJohannes Berg <[email protected]>
Thu, 2 Jul 2009 13:46:41 +0000 (15:46 +0200)
committerJohn W. Linville <[email protected]>
Tue, 7 Jul 2009 16:55:28 +0000 (12:55 -0400)
The code in cfg80211's cfg80211_bss_update erroneously
grabs a reference to the BSS, which means that it will
never be freed.

Signed-off-by: Johannes Berg <[email protected]>
Cc: [email protected] [2.6.29, 2.6.30]
Signed-off-by: John W. Linville <[email protected]>
net/wireless/scan.c

index e95b638b919f5dba4203a0959c0437fd612f239e..f8e71b300001e3a6ef5bde1f774d3c44e47ff2a0 100644 (file)
@@ -366,7 +366,6 @@ cfg80211_bss_update(struct cfg80211_registered_device *dev,
        found = rb_find_bss(dev, res);
 
        if (found) {
-               kref_get(&found->ref);
                found->pub.beacon_interval = res->pub.beacon_interval;
                found->pub.tsf = res->pub.tsf;
                found->pub.signal = res->pub.signal;