Re: net: lapbether: fix double free

2017-10-31 Thread David Miller
From: Pan Bian Date: Sun, 29 Oct 2017 21:57:22 +0800 > The function netdev_priv() returns the private data of the device. The > memory to store the private data is allocated in alloc_netdev() and is > released in netdev_free(). Calling kfree() on the return value of >

net: lapbether: fix double free

2017-10-29 Thread Pan Bian
The function netdev_priv() returns the private data of the device. The memory to store the private data is allocated in alloc_netdev() and is released in netdev_free(). Calling kfree() on the return value of netdev_priv() after netdev_free() results in a double free bug. Signed-off-by: Pan Bian