From: Theodore Ts'o Date: Thu, 6 Mar 2003 17:22:52 +0000 (-0500) Subject: Bug fix; we were incorrectly moving the block and inode bitmaps X-Git-Tag: E2FSPROGS-1_33-WIP-0306~5 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=424cb7b62aa417db2eaec79cfaec7433b31f8726;p=thirdparty%2Fe2fsprogs.git Bug fix; we were incorrectly moving the block and inode bitmaps for sparse superblock filesystems. (Address Debian bug #174766) --- diff --git a/resize/ChangeLog b/resize/ChangeLog index 1e01ffdf8..96d18a5cd 100644 --- a/resize/ChangeLog +++ b/resize/ChangeLog @@ -1,3 +1,9 @@ +2003-03-06 + + * resize2fs.c (blocks_to_move): Bug fix; we were incorrectly + moving the block and inode bitmaps for sparse superblock + filesystems. (Address Debian bug #174766) + 2002-11-09 Theodore Ts'o * Release of E2fsprogs 1.32 diff --git a/resize/resize2fs.c b/resize/resize2fs.c index 7494f8f57..f9543ccbf 100644 --- a/resize/resize2fs.c +++ b/resize/resize2fs.c @@ -656,9 +656,12 @@ static errcode_t blocks_to_move(ext2_resize_t rfs) if (!(fs->super->s_feature_incompat & EXT2_FEATURE_INCOMPAT_META_BG) || (meta_bg < fs->super->s_first_meta_bg)) { - for (blk = group_blk+1; - blk < group_blk + 1 + new_blocks; blk++) - mark_fs_metablock(rfs, meta_bmap, i, blk); + if (has_super) { + for (blk = group_blk+1; + blk < group_blk + 1 + new_blocks; blk++) + mark_fs_metablock(rfs, meta_bmap, + i, blk); + } } else { if (has_super) has_super = 1;