diff options
author | Qu Wenruo <wqu@suse.com> | 2018-06-06 15:27:17 +0800 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2018-08-06 15:01:16 +0200 |
commit | 866740418ccf881fcc64a4633978e3621ed4a7fc (patch) | |
tree | 873ac96a0d43f2e86a801835e3581d533680087f | |
parent | eca8dc0757f574097791104683f451740ae62057 (diff) |
btrfs-progs: fsck-tests: Add test case for corrupted inline ram_bytes
Signed-off-by: Qu Wenruo <wqu@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
-rw-r--r-- | tests/fsck-tests/035-inline-bad-ram-bytes/offset_by_one.img | bin | 0 -> 3072 bytes | |||
-rwxr-xr-x | tests/fsck-tests/035-inline-bad-ram-bytes/test.sh | 11 |
2 files changed, 11 insertions, 0 deletions
diff --git a/tests/fsck-tests/035-inline-bad-ram-bytes/offset_by_one.img b/tests/fsck-tests/035-inline-bad-ram-bytes/offset_by_one.img Binary files differnew file mode 100644 index 00000000..2f58208e --- /dev/null +++ b/tests/fsck-tests/035-inline-bad-ram-bytes/offset_by_one.img diff --git a/tests/fsck-tests/035-inline-bad-ram-bytes/test.sh b/tests/fsck-tests/035-inline-bad-ram-bytes/test.sh new file mode 100755 index 00000000..6f6e2a5e --- /dev/null +++ b/tests/fsck-tests/035-inline-bad-ram-bytes/test.sh @@ -0,0 +1,11 @@ +#!/bin/bash +# Around 2014, btrfs kernel has a regression that create inline extent +# with ram_bytes offset by one. +# This old regression could be caught by tree-check code. +# This test case will check if btrfs check could detect and repair it. + +source "$TEST_TOP/common" + +check_prereq btrfs + +check_all_images |