fs/ext4: ext4_find_extent(): remove unmeetable inconsisteny check
PATCH 1/1 fs/ext4: ext4_find_extent(): remove unmeetable inconsisteny check
ext4_find_extent(), stripped down to the parts relevant to this patch, reads as
ppos = 0;
i = depth;
while (i) {
--i;
++ppos;
if (unlikely(ppos > depth)) {
...
ret = -EFSCORRUPTED;
goto err;
}
}Due to the loop's bounds, the condition ppos > depth can never be met.
Remove this dead code.
Signed-off-by Nicolai Stange <[email protected]>
---
Applicable to linux-next-20150415.
fs/ext4/extents.c | 7 ------- 1 file changed, 7 deletions(-)
fs/ext4/extents.c +0 -7
@@ -907,13 +907,6 @@ ext4_find_extent(struct inode *inode, ext4_lblk_t block, eh =ext_block_hdr (bh); ppos++; -if (unlikely (ppos > depth)) { -put_bh (bh); -EXT4_ERROR_INODE (inode, -"ppos %d > depth %d" , ppos, depth); - ret = -EFSCORRUPTED ; - goto err; - } path[ppos].p_bh = bh; path[ppos].p_hdr = eh; }
Signature · 1 line
2.8.1