[PATCH] sector_t last is unsigned, so cannot be less than 0.

From: Roel Kluin
Date: Sun Jan 18 2009 - 17:45:29 EST


sector_t last is unsigned, so cannot be less than 0.

Signed-off-by: Roel Kluin <roel.kluin@xxxxxxxxx>
---
diff --git a/fs/udf/super.c b/fs/udf/super.c
index e25e701..1f3941d 100644
--- a/fs/udf/super.c
+++ b/fs/udf/super.c
@@ -721,7 +721,7 @@ static sector_t udf_scan_anchors(struct super_block *sb, sector_t lastblock)
* however, if the disc isn't closed, it could be 512 */

for (i = 0; i < ARRAY_SIZE(last); i++) {
- if (last[i] < 0)
+ if (last[i] > lastblock + 1)
continue;
if (last[i] >= sb->s_bdev->bd_inode->i_size >>
sb->s_blocksize_bits)
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/