summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2012-03-30 20:39:15 +0200
committerAl Viro <viro@zeniv.linux.org.uk>2012-03-31 22:03:16 +0200
commita6ecdfcfba9392f469992dd6016ceafb3ea62123 (patch)
tree0a818c7e050c3a5aa59852020567fb70a5cdcf47 /fs
parentuntangling do_lookup() - merge failure exits in !dentry case (diff)
downloadlinux-a6ecdfcfba9392f469992dd6016ceafb3ea62123.tar.xz
linux-a6ecdfcfba9392f469992dd6016ceafb3ea62123.zip
untangling do_lookup() - merge d_alloc_and_lookup() callers
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs')
-rw-r--r--fs/namei.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/namei.c b/fs/namei.c
index a0f9a0294ff2..1d60fdf01b37 100644
--- a/fs/namei.c
+++ b/fs/namei.c
@@ -1188,12 +1188,12 @@ retry:
}
if (!d_invalidate(dentry)) {
dput(dentry);
- dentry = d_alloc_and_lookup(parent, name, nd);
+ dentry = NULL;
}
}
- } else if (!dentry) {
- dentry = d_alloc_and_lookup(parent, name, nd);
}
+ if (!dentry)
+ dentry = d_alloc_and_lookup(parent, name, nd);
l:
mutex_unlock(&dir->i_mutex);
if (IS_ERR(dentry))