isofs: inode leak on mount failure

d_alloc_root() failure leaves root inode leaked...

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
This commit is contained in:
Al Viro 2012-01-09 10:48:11 -05:00
parent 0ce8c0109f
commit 8fdd8c49fe

View File

@ -948,8 +948,11 @@ root_found:
/* get the root dentry */
s->s_root = d_alloc_root(inode);
if (!(s->s_root))
goto out_no_root;
if (!(s->s_root)) {
iput(inode);
error = -ENOMEM;
goto out_no_inode;
}
kfree(opt.iocharset);