summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
Diffstat (limited to 'fs')
-rw-r--r--fs/squashfs/namei.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/fs/squashfs/namei.c b/fs/squashfs/namei.c
index 4bc63ac..51b3695 100644
--- a/fs/squashfs/namei.c
+++ b/fs/squashfs/namei.c
@@ -232,10 +232,7 @@ static struct dentry *squashfs_lookup(struct inode *dir, struct dentry *dentry,
exit_lookup:
kfree(dire);
- if (inode)
- return d_splice_alias(inode, dentry);
- d_add(dentry, inode);
- return ERR_PTR(0);
+ return d_splice_alias(inode, dentry);
data_error:
err = -EIO;
OpenPOWER on IntegriCloud