aboutsummaryrefslogtreecommitdiffstats
path: root/fs/gfs2
diff options
context:
space:
mode:
Diffstat (limited to 'fs/gfs2')
-rw-r--r--fs/gfs2/inode.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/gfs2/inode.c b/fs/gfs2/inode.c
index e62e59477884..9317ddc1b3c3 100644
--- a/fs/gfs2/inode.c
+++ b/fs/gfs2/inode.c
@@ -840,8 +840,10 @@ static struct dentry *__gfs2_lookup(struct inode *dir, struct dentry *dentry,
840 int error; 840 int error;
841 841
842 inode = gfs2_lookupi(dir, &dentry->d_name, 0); 842 inode = gfs2_lookupi(dir, &dentry->d_name, 0);
843 if (!inode) 843 if (inode == NULL) {
844 d_add(dentry, NULL);
844 return NULL; 845 return NULL;
846 }
845 if (IS_ERR(inode)) 847 if (IS_ERR(inode))
846 return ERR_CAST(inode); 848 return ERR_CAST(inode);
847 849