Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 19 Jul 2006 22:09:36 +0900
From:      gnn@freebsd.org
To:        "Tom Parker" <wiresncode@gmail.com>
Cc:        freebsd-net@freebsd.org
Subject:   Re: Possible inconsistency in the use of in6_delmulti()
Message-ID:  <m21wshaghb.wl%gnn@neville-neil.com>
In-Reply-To: <9050f13e0607181203r610da712kc506507b4f90b77c@mail.gmail.com>
References:  <9050f13e0607181203r610da712kc506507b4f90b77c@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
At Tue, 18 Jul 2006 12:03:20 -0700,
Tom Parker wrote:
> 
> Hi,
> 
> New to the list here, but fairly familiar with the innards of (at
> least an older) version of the fbsd networking code. I'm fortunate in
> my ability to run purify on a simulated instance of our ported version
> of the networking code.  Purify has picked up a problem that I'm a bit
> mystified as how it can be fixed.  It is present in current versions
> also, I'm interested in any comments people have (I think ours is 4.4
> vintage, but it is hard to tell).
> 
> As far as I can tell, in most calling paths when in6_delmulti() is
> called, it is done after the in6_multi_mship structure has been
> removed from the im6o_memberships list in the relevant PCB.  This
> applies to in6_ifdetach(), in6_pcbpurgeif0, ip6_setmoptions()  etc.
> However in in6_purgeaddr() in6_delmulti is called straight off.  I'm
> not sure if we've violated some usage convention, but purify is
> telling me this causes access violations when we then leave the same
> group using setsockopt().  in6_purgeaddr is called when we remove the
> address from the interface.
> 
> This should be possible in a real kernel.  Add a multicast address to
> an interface, open a socket and listen to the address, then remove the
> address from the interface.
> 
> Am I missing something here or is this a nasty problem in both the
> kernel and our stack port?
> 

It sounds like a bug to me.  Can you file a PR?

Thanks,
George



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?m21wshaghb.wl%gnn>