* [2.5] memleak in fs/nfs/inode.c::nfs_get_sb()
@ 2003-03-11 15:11 Oleg Drokin
0 siblings, 0 replies; only message in thread
From: Oleg Drokin @ 2003-03-11 15:11 UTC (permalink / raw)
To: trond.myklebust, torvalds, linux-kernel
Hello!
There is trivial memleak on error exit path in nfs get_sb function.
See the patch.
Found with the help of smatch + enhanced unfree script.
Bye,
Oleg
===== fs/nfs/inode.c 1.72 vs edited =====
--- 1.72/fs/nfs/inode.c Thu Feb 13 15:57:46 2003
+++ edited/fs/nfs/inode.c Tue Mar 11 18:03:07 2003
@@ -1231,6 +1231,7 @@
if (root->size > sizeof(root->data)) {
printk("nfs_get_sb: invalid root filehandle\n");
+ kfree(server);
return ERR_PTR(-EINVAL);
}
/* We now require that the mount process passes the remote address */
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2003-03-11 15:00 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-03-11 15:11 [2.5] memleak in fs/nfs/inode.c::nfs_get_sb() Oleg Drokin
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.