From: Jesper Juhl Date: Fri, 24 Dec 2010 22:22:37 +0000 (+0000) Subject: NFS: Don't leak in nfs_proc_symlink() X-Git-Tag: v2.6.38-rc1~407^2~40 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=878215feb8b2417c4700090b4335739858cf7b5a;p=pandora-kernel.git NFS: Don't leak in nfs_proc_symlink() Hi, In fs/nfs/proc.c::nfs_proc_symlink() we will leak memory if either nfs_alloc_fhandle() or nfs_alloc_fattr() returns NULL but the other one doesn't. This patch ensures memory allocated by one when the other fails is always released (this is safe since nfs_free_fattr() and nfs_free_fhandle() both call kfree which deals gracefully with NULL pointers). Signed-off-by: Jesper Juhl Signed-off-by: Trond Myklebust --- Reading git-diff-tree failed