The following commit has been merged in the master branch: commit 666c47db54d39b3e616059e9c04cda7ac9ba04ce Author: simon simon@45894c77-fb22-0410-b583-ff6e7d5dbf6c Date: Sat Nov 7 13:29:35 2009 +0000
fix memory leak when there is a problem adding an interface
git-svn-id: http://downloads.open-mesh.net/svn/batman/trunk/batman-adv-kernelland@1468 45894c77-fb22-0410-b583-ff6e7d5dbf6c
diff --git a/hard-interface.c b/hard-interface.c index e0d0342..fdc5add 100644 --- a/hard-interface.c +++ b/hard-interface.c @@ -400,6 +400,8 @@ int hardif_add_interface(char *dev, int if_num) return 1;
out: + if (batman_if->packet_buff) + kfree(batman_if->packet_buff); kfree(batman_if); kfree(dev); return -1;