summaryrefslogtreecommitdiffstats
path: root/fs/ocfs2
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2023-11-14 18:20:22 +0100
committerAl Viro <viro@zeniv.linux.org.uk>2023-12-21 18:53:30 +0100
commitfda43691041c7ee685da903641402a0f913fe9e9 (patch)
tree4fcff3f035da56cc5ee345fdd411afa1a3f2f326 /fs/ocfs2
parentreiserfs_add_entry(): get rid of pointless namelen checks (diff)
downloadlinux-fda43691041c7ee685da903641402a0f913fe9e9.tar.xz
linux-fda43691041c7ee685da903641402a0f913fe9e9.zip
ocfs2_find_match(): there's no such thing as NULL or negative ->d_parent
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/ocfs2')
-rw-r--r--fs/ocfs2/dcache.c7
1 files changed, 0 insertions, 7 deletions
diff --git a/fs/ocfs2/dcache.c b/fs/ocfs2/dcache.c
index 04fc8344063a..a9b8688aaf30 100644
--- a/fs/ocfs2/dcache.c
+++ b/fs/ocfs2/dcache.c
@@ -124,17 +124,10 @@ static int ocfs2_match_dentry(struct dentry *dentry,
if (!dentry->d_fsdata)
return 0;
- if (!dentry->d_parent)
- return 0;
-
if (skip_unhashed && d_unhashed(dentry))
return 0;
parent = d_inode(dentry->d_parent);
- /* Negative parent dentry? */
- if (!parent)
- return 0;
-
/* Name is in a different directory. */
if (OCFS2_I(parent)->ip_blkno != parent_blkno)
return 0;