lkml.org 
[lkml]   [2009]   [Dec]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [RFC] macvlan: add tap device backend
Date
On Monday 14 December 2009, Patrick McHardy wrote:
> > + classdev = device_create(macvtap_class, &dev->dev, devt,
> > + dev, "tap%d", dev->ifindex);
> > + if (IS_ERR(classdev)) {
> > + err = PTR_ERR(classdev);
> > + macvtap_del_queues(dev);
> > + macvlan_dellink(dev, NULL);
>
> I think this may cause a double free since macvlan_dellink() will
> free the device and rtnl_newlink() will free it again on error.

Ah, right. I've changed this part a few times now, but I think introduced
the same bug again in the current version. I'll send out what I have now
if you want to take another look.

Arnd


\
 
 \ /
  Last update: 2009-12-14 16:43    [W:0.037 / U:19.316 seconds]
©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site