diff options
-rw-r--r-- | fs/gfs2/inode.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/gfs2/inode.c b/fs/gfs2/inode.c index 57c43ac47925..d470e5286ecd 100644 --- a/fs/gfs2/inode.c +++ b/fs/gfs2/inode.c | |||
@@ -157,6 +157,9 @@ struct inode *gfs2_inode_lookup(struct super_block *sb, struct gfs2_inum *inum, | |||
157 | struct gfs2_glock *io_gl; | 157 | struct gfs2_glock *io_gl; |
158 | int error; | 158 | int error; |
159 | 159 | ||
160 | if (!inode) | ||
161 | return ERR_PTR(-ENOBUFS); | ||
162 | |||
160 | if (inode->i_state & I_NEW) { | 163 | if (inode->i_state & I_NEW) { |
161 | struct gfs2_sbd *sdp = GFS2_SB(inode); | 164 | struct gfs2_sbd *sdp = GFS2_SB(inode); |
162 | umode_t mode = DT2IF(type); | 165 | umode_t mode = DT2IF(type); |