mirror of https://github.com/vitalif/e2fsprogs
libext2fs: Fix FLEX_BG offset used by ext2fs_allocate_group_table
The offset for both inode bitmaps and inode tables is overshot by one block causing a hole between the group of bitmaps and inode tables when initializing a filesystem using mke2fs. Signed-off-by: Jose R. Santos <jrs@us.ibm.com> Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>bitmap-optimize
parent
ab06396f70
commit
ba4a021009
|
@ -46,8 +46,11 @@ static blk_t flexbg_offset(ext2_filsys fs, dgrp_t group, blk_t start_blk,
|
|||
if (size > (int) (fs->super->s_blocks_per_group / 8))
|
||||
size = (int) fs->super->s_blocks_per_group / 8;
|
||||
|
||||
if (offset)
|
||||
offset -= 1;
|
||||
|
||||
/*
|
||||
* Dont do a long search if the previous block
|
||||
* Don't do a long search if the previous block
|
||||
* search is still valid.
|
||||
*/
|
||||
if (start_blk && group % flexbg_size) {
|
||||
|
|
Loading…
Reference in New Issue