nfs: Fix nfs_parse_mount_options() kfree() leak
Subsystems (2)
PATCH 1/1 nfs: Fix nfs_parse_mount_options() kfree() leak
From: Yinghai Lu <[email protected]>
Fix a (small) memory leak in one of the error paths of the NFS mount options parsing code.
Reported-by Yinghai Lu <[email protected]>
Reported-by Pekka Enberg <penberg-bbCR+/[email protected]>
Signed-off-by Ingo Molnar <[email protected]>
Signed-off-by Trond Myklebust <[email protected]>
---
Regression introduced in 2.6.30 by commit a67d18f (NFS: load the rpc/rdma transport module automatically). Please apply to mainline +stable...
fs/nfs/super.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
fs/nfs/super.c +1 -0
@@ -1253,6 +1253,7 @@ static int nfs_parse_mount_options(char *raw,default :dfprintk (MOUNT ,"NFS: unrecognized " "transport protocol\n" ); +kfree (string);return 0 ; }break ;