Re: [PATCH] Re: Wired + Wireless cohexistence issues, using libnl3



On Thu, 2011-09-29 at 18:09 -0500, Dan Williams wrote:
> On Wed, 2011-09-28 at 12:09 -0400, Mathieu Trudel-Lapierre wrote:
> > So I actually found the cause for the missing routes in the libnl
> > cache: in nm_netlink_foreach_route(), when rtnl_route_alloc_cache() is
> > called, it is done with the NL_AUTO_PROVIDE flag. I don't know why
> > this was added; but replacing it with 0 (no flags), fixes the issue
> > with no apparent drawbacks.
> > 
> > A patch is attached.
> 
> Thomas, any idea what might be going on here?

The cache is freed even though it is provided. The provide/require
feature does not do reference counting so the pointer is stored for
use even though it has been freed. Not sure if NM ever looks up the
provided cache via _require() or if libnl uses it internally (I don't
think libnl ever requires a route cache internally) but if either
happens, it would cause memory corruption.



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]