ocfs2: add IO error check in ocfs2_get_sector()
[safe/jmp/linux-2.6] / fs / ext4 / ext4.h
index aafc9eb..b0c87dc 100644 (file)
@@ -868,7 +868,7 @@ static inline unsigned ext4_rec_len_from_disk(__le16 dlen)
 {
        unsigned len = le16_to_cpu(dlen);
 
-       if (len == EXT4_MAX_REC_LEN)
+       if (len == EXT4_MAX_REC_LEN || len == 0)
                return 1 << 16;
        return len;
 }