]> git.ipfire.org Git - thirdparty/e2fsprogs.git/commitdiff
Define an error code for block bitmap checksum failures
authorDarrick J. Wong <darrick.wong@oracle.com>
Sun, 13 Oct 2013 03:11:25 +0000 (23:11 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Sun, 13 Oct 2013 03:11:31 +0000 (23:11 -0400)
Apparently libext2fs didn't have an error code defined for block
bitmap checksum errors, so add one.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Reviewed-by: Lukas Czerner <lczerner@redhat.com>
lib/ext2fs/ext2_err.et.in
lib/ext2fs/rw_bitmaps.c

index e719864dda9766774e2e3e84d4648ca099125ae6..c547a2cd88cd7d0cdfa8fd90687dd85be6554116 100644 (file)
@@ -476,4 +476,7 @@ ec  EXT2_ET_MMP_CSUM_INVALID,
 ec     EXT2_ET_FILE_EXISTS,
        "Ext2 file already exists"
 
+ec     EXT2_ET_BLOCK_BITMAP_CSUM_INVALID,
+       "Block bitmap checksum does not match bitmap"
+
        end
index cc14aaf8d16ba47d2fd76a9f24d7ee4fa41f5234..386cbebbca44cc235e26e2a2ab2a703ab8a687fa 100644 (file)
@@ -275,7 +275,7 @@ static errcode_t read_bitmaps(ext2_filsys fs, int do_inode, int do_block)
                                    !ext2fs_block_bitmap_csum_verify(fs, i,
                                                block_bitmap, block_nbytes)) {
                                        retval =
-                                       EXT2_ET_BLOCK_BITMAP_READ;
+                                       EXT2_ET_BLOCK_BITMAP_CSUM_INVALID;
                                        goto cleanup;
                                }
                        } else