public inbox for netdev@vger.kernel.org 
 help / color / mirror / Atom feed
From: Toshiaki Makita <makita.toshiaki@lab•ntt.co.jp>
To: Dave Jones <davej@redhat•com>,
	Toshiaki Makita <toshiaki.makita1@gmail•com>
Cc: netdev@vger•kernel.org
Subject: Re: new leaks in bridging code.
Date: Mon, 31 Mar 2014 12:54:06 +0900	[thread overview]
Message-ID: <5338E6DE.8080702@lab.ntt.co.jp> (raw)
In-Reply-To: <20140330024709.GA25793@redhat.com>

(2014/03/30 11:47), Dave Jones wrote:
> On Sun, Mar 30, 2014 at 11:28:21AM +0900, Toshiaki Makita wrote:
>  > On Sat, 2014-03-29 at 17:01 -0400, Dave Jones wrote:
>  > > yesterdays bridging changes introduced leaks in the exit paths..
>  > > 
>  > The patch has nothing to do with this memory leak.
> 
> Good point, the checker only picked up it as 'new' because of the
> additional call to vlan_untag.
> 
>  > It has existed since br_allowed_ingress was introduced.
>  > I'm working on fixing it.
>  > http://marc.info/?t=139598775400004&r=1&w=2
> 
> Great! (I'm behind on email so hadn't seen this thread).
> 

Considering more deeply about why your checker claimed that vlan_untag()
in br_allowed_ingress() is bad, I got an idea that it should have
pointed out not resource leakage but double free of skb.

vlan_untag() may free skbs, but we also free skbs in caller side
(br_handle_frame_finish()) without updating skb pointers to NULL.

I'll also fix this problem.

Thanks,
Toshiaki Makita

      reply	other threads:[~2014-03-31  3:54 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <533730f2396e8_1c4bb46874192e@209.249.196.67.mail>
2014-03-29 21:01 ` new leaks in bridging code Dave Jones
2014-03-30  2:28   ` Toshiaki Makita
2014-03-30  2:47     ` Dave Jones
2014-03-31  3:54       ` Toshiaki Makita [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5338E6DE.8080702@lab.ntt.co.jp \
    --to=makita.toshiaki@lab$(echo .)ntt.co.jp \
    --cc=davej@redhat$(echo .)com \
    --cc=netdev@vger$(echo .)kernel.org \
    --cc=toshiaki.makita1@gmail$(echo .)com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox