diff options
Diffstat (limited to 'fs')
-rw-r--r-- | fs/ext4/ext4_journal.c | 4 | ||||
-rw-r--r-- | fs/fat/fat_write.c | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/fs/ext4/ext4_journal.c b/fs/ext4/ext4_journal.c index 5a25be4c8ac..fed6287eac4 100644 --- a/fs/ext4/ext4_journal.c +++ b/fs/ext4/ext4_journal.c @@ -355,7 +355,7 @@ void recover_transaction(int prev_desc_logical_no) ofs = sizeof(struct journal_header_t); do { - tag = (struct ext3_journal_block_tag *)&p_jdb[ofs]; + tag = (struct ext3_journal_block_tag *)(p_jdb + ofs); ofs += sizeof(struct ext3_journal_block_tag); if (ofs > fs->blksz) @@ -466,7 +466,7 @@ int ext4fs_check_journal_state(int recovery_flag) ofs = sizeof(struct journal_header_t); do { tag = (struct ext3_journal_block_tag *) - &p_jdb[ofs]; + (p_jdb + ofs); ofs += sizeof(struct ext3_journal_block_tag); if (ofs > fs->blksz) break; diff --git a/fs/fat/fat_write.c b/fs/fat/fat_write.c index f6f06289f40..4ca024c2088 100644 --- a/fs/fat/fat_write.c +++ b/fs/fat/fat_write.c @@ -762,7 +762,7 @@ static int check_overflow(fsdata *mydata, __u32 clustnum, loff_t size) if (offset != 0) sect_num++; - if (startsect + sect_num > cur_part_info.start + total_sector) + if (startsect + sect_num > total_sector) return -1; return 0; } |