From: Al Viro Date: Fri, 9 Oct 2015 00:18:00 +0000 (-0400) Subject: orangefs: double iput() in case of d_make_root() failure X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=b05a7851095c24ff62d5ffeb81baeffe7acd26a2;p=linux-beck.git orangefs: double iput() in case of d_make_root() failure Signed-off-by: Al Viro Signed-off-by: Mike Marshall --- diff --git a/fs/orangefs/super.c b/fs/orangefs/super.c index 9dee95293599..833af68c2227 100644 --- a/fs/orangefs/super.c +++ b/fs/orangefs/super.c @@ -403,10 +403,8 @@ static int pvfs2_fill_sb(struct super_block *sb, void *data, int silent) /* allocates and places root dentry in dcache */ root_dentry = d_make_root(root); - if (!root_dentry) { - iput(root); + if (!root_dentry) return -ENOMEM; - } sb->s_export_op = &pvfs2_export_ops; sb->s_root = root_dentry;