diff options
Diffstat (limited to 'fs/ext4/dir.c')
-rw-r--r-- | fs/ext4/dir.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/ext4/dir.c b/fs/ext4/dir.c index f8595787a70e..f2ed3e7fb9f5 100644 --- a/fs/ext4/dir.c +++ b/fs/ext4/dir.c | |||
@@ -153,6 +153,9 @@ static int ext4_readdir(struct file * filp, | |||
153 | ext4_error (sb, "ext4_readdir", | 153 | ext4_error (sb, "ext4_readdir", |
154 | "directory #%lu contains a hole at offset %lu", | 154 | "directory #%lu contains a hole at offset %lu", |
155 | inode->i_ino, (unsigned long)filp->f_pos); | 155 | inode->i_ino, (unsigned long)filp->f_pos); |
156 | /* corrupt size? Maybe no more blocks to read */ | ||
157 | if (filp->f_pos > inode->i_blocks << 9) | ||
158 | break; | ||
156 | filp->f_pos += sb->s_blocksize - offset; | 159 | filp->f_pos += sb->s_blocksize - offset; |
157 | continue; | 160 | continue; |
158 | } | 161 | } |