btrfs-progs/tests/misc-tests
Mike Fleetwood 7b6922c988 btrfs-progs: dump-super: exit with failure when printing bad superblock
Attempting to dump a bad btrfs superblock returns successful exit status
zero.  According to the manual page non-zero should be returned on
failure.  Fix this.

    $ btrfs inspect-internal dump-super /dev/zero
    superblock: bytenr=65536, device=/dev/zero
    ---------------------------------------------------------
    ERROR: bad magic on superblock on /dev/zero at 65536

    $ echo $?
    0

Signed-off-by: Mike Fleetwood <mike.fleetwood@googlemail.com>
Signed-off-by: David Sterba <dsterba@suse.com>
2022-08-16 15:18:12 +02:00
..
001-btrfstune-features
002-uuid-rewrite
003-zero-log
004-shrink-fs btrfs-progs: tests: filter output for run_check_stdout 2020-05-04 20:48:42 +02:00
005-convert-progress-thread-crash
006-image-on-missing-device
007-subvolume-sync
008-leaf-crossing-stripes
009-subvolume-sync-must-wait btrfs-progs: tests: filter output for run_check_stdout 2020-05-04 20:48:42 +02:00
010-convert-delete-ext2-subvol
011-delete-missing-device
012-find-root-no-result
013-subvolume-sync-crash btrfs-progs: tests: filter output for run_check_stdout 2020-05-04 20:48:42 +02:00
014-filesystem-label
015-dump-super-garbage btrfs-progs: dump-super: exit with failure when printing bad superblock 2022-08-16 15:18:12 +02:00
016-send-clone-src
017-recv-stream-malformatted
018-recv-end-of-stream
019-receive-clones-on-mounted-subvol
020-fix-superblock-corruption
021-image-multi-devices
022-filesystem-du-on-empty-subvol
023-device-usage-with-missing-device
024-inspect-internal-rootid btrfs-progs: tests: filter output for run_check_stdout 2020-05-04 20:48:42 +02:00
025-zstd-compression btrfs-progs: tests: switch mktemp to local helpers 2021-10-20 18:59:24 +02:00
026-image-non-printable-chars
027-subvol-list-deleted-toplevel
028-superblock-recover
029-send-p-different-mountpoints
030-missing-device-image
031-qgroup-parent-child-relation btrfs-progs: tests: filter output for run_check_stdout 2020-05-04 20:48:42 +02:00
032-bad-item-ptr
033-filename-length-limit
034-metadata-uuid btrfs-progs: lots of typo fixes (codespell) 2020-03-31 18:37:38 +02:00
035-receive-common-mount-point-prefix
036-receive-dump-invalid-stream
037-fi-show-on-new-file btrfs-progs: tests: unify mktemp file name pattern 2021-10-20 18:59:24 +02:00
038-backup-root-corruption btrfs-progs: tests: make misc/038 more robust when searching backup slots 2021-10-20 18:59:24 +02:00
039-receive-clone-from-current-subvolume
040-subvolume-delete-default btrfs-progs: tests: add case for deleting default subvolume 2020-10-02 20:12:08 +02:00
041-subvolume-delete-during-send btrfs-progs: tests: add case for send vs subvolume deletion 2020-10-02 20:12:08 +02:00
042-inspect-internal-logical-resolve btrfs-progs: tests: test logical-resolve in various scenarios 2021-01-18 17:49:22 +01:00
043-subvolume-set-default-toplevel btrfs-progs: tests: set toplevel subvolume as default when specified as 0 2021-01-18 17:49:23 +01:00
045-receive-check-mount-type btrfs-progs: receive: fix btrfs_mount_root substring bug 2021-02-19 16:29:40 +01:00
046-seed-multi-mount btrfs-progs: tests: fix quoting of sudo helper in misc/046-seed-multi-mount 2021-03-15 15:40:54 +01:00
047-raid5-convert btrfs-progs: balance: fix raid56 warning for other profiles 2021-03-23 17:04:22 +01:00
048-image-restore-mount btrfs-progs: tests: switch mktemp to local helpers 2021-10-20 18:59:24 +02:00
049-btrfstune-transid-mismatch btrfs-progs: tests: test case to make sure btrfstune rejects corrupted fs 2021-09-20 12:26:20 +02:00
050-receive-prop-ro-to-rw btrfs-progs: tests: subvolume ro->rw switch and received_uuid 2021-10-07 18:40:29 +02:00
051-warning-rw-subvol-received-uuid btrfs-progs: fix read-write subvol and received_uuid flags check 2021-11-04 20:56:42 +01:00
052-seed-dirty-log btrfs-progs: make sure "btrfstune -S1" will reject fs with dirty log 2022-04-25 18:30:28 +02:00
053-receive-write-encoded btrfs-progs: receive: add tests for basic encoded_write send/receive 2022-08-16 15:18:09 +02:00