Re: Possible memory leak in net/wireless/scan.c



On Tue, 2009-07-07 at 18:04 +0100, Catalin Marinas wrote:

diff --git a/net/wireless/scan.c b/net/wireless/scan.c
index e95b638..f8e71b3 100644
--- a/net/wireless/scan.c
+++ b/net/wireless/scan.c
@@ -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;

I'll try this later today to see if it fixes the leak. If that's not
correct, I'll post more information about the content of the reported
object (in general, it shouldn't be on any valid list or rb tree since
kmemleak can't find it).

I have already sent that exact patch.

johannes

Attachment: signature.asc
Description: This is a digitally signed message part



Relevant Pages

  • Re: Possible memory leak in net/wireless/scan.c
    ... I'll try this later today to see if it fixes the leak. ... I can now confirm that it fixes the memory leak. ...
    (Linux-Kernel)
  • Re: [git pull] drm fixes
    ... Speaking of which, what about leak fixes? ... The third jffs2 patch in that tree is a fix for ctime semantics which is ... Not strictly a regression, as it's a new driver in 2.6.35 -- ...
    (Linux-Kernel)
  • Re: pull request: wireless-2.6 2008-11-18
    ... Three fixes from Johannes, intended for 2.6.28... ... libertas_tf: fix skb tail pointer ... struct iwl_rx_mem_buffer { ...
    (Linux-Kernel)
  • Re: pull request: wireless-2.6 2008-11-18
    ... Three fixes from Johannes, intended for 2.6.28... ... libertas_tf: fix skb tail pointer ... struct iwl_rx_mem_buffer { ...
    (Linux-Kernel)
  • pull request: wireless-2.6 2008-11-18
    ... Three fixes from Johannes, intended for 2.6.28... ... libertas_tf: fix skb tail pointer ... struct iwl_rx_mem_buffer { ...
    (Linux-Kernel)