e2fsprogs/lib
Darrick J. Wong d36b957b34 libext2fs: don't always read backup group descriptors on a 1k-block meta_bg fs
On a filesystem with 1K blocks and meta_bg enabled, opening a
filesystem with automatic superblock detection tries to compensate for
the fact that the superblock lives in block 1.  However, the method by
which this is done is later misinterpreted to mean "read the backup
group descriptors", which is not what we want in this case.

Therefore, in ext2fs_open3() separate the 'group zero' adjustment into
its own variable so that we don't get fed backup group descriptors
when we try to load meta_bg group descriptors.

Furthermore, enhance ext2fs_descriptor_block_loc2() to perform its own
group zero correction.  The other caller of this function neglects to
do any group-zero correction of their own, so this fixes them too.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
2014-01-11 13:58:15 -05:00
..
blkid libblkid: add error checking for rename() while saving the blkid cache 2014-01-10 22:09:45 -05:00
e2p e2fsck: verify s_desc_size is power-of-two value 2013-12-23 16:03:46 -05:00
et Use makeinfo --html instead of texi2html 2013-12-28 15:40:56 -05:00
ext2fs libext2fs: don't always read backup group descriptors on a 1k-block meta_bg fs 2014-01-11 13:58:15 -05:00
quota libquota: add error checking to quota_remove_inode 2014-01-07 09:10:24 -05:00
ss libss: fix potential null dereference if realloc() fails 2014-01-10 21:13:15 -05:00
uuid libuuid: add error checking to syscalls in get_clock() 2014-01-10 21:06:07 -05:00
Makefile.bsd-lib Include LDFLAGS when building BSD libraries 2012-05-11 22:21:08 -04:00
Makefile.checker Add configure options --enable-symlink-build and --enable-symlink-install 2010-05-17 19:21:42 -04:00
Makefile.darwin-lib Add configure options --enable-symlink-build and --enable-symlink-install 2010-05-17 19:21:42 -04:00
Makefile.elf-lib Put ELF_OTHER_LIBS in the right place for the linker 2012-08-06 12:30:49 -04:00
Makefile.library Add configure options --enable-symlink-build and --enable-symlink-install 2010-05-17 19:21:42 -04:00
Makefile.profile Add configure options --enable-symlink-build and --enable-symlink-install 2010-05-17 19:21:42 -04:00
Makefile.solaris-lib Put ELF_OTHER_LIBS in the right place for the linker 2012-08-06 12:30:49 -04:00
config.h.in e4defrag: choose the best available posix_fadvise variant 2014-01-05 22:55:10 -05:00
dirpaths.h.in Shorten compile commands run by the build system 2011-09-18 17:34:37 -04:00
fpopen.c Shorten compile commands run by the build system 2011-09-18 17:34:37 -04:00