Have dumpfs(8) ignore superblock check-hash failures.

Set the STDSB_NOHASHFAIL request so that dumpfs(8) can print out
filesystem details even when the superblock checksum is incorrect.
This commit is contained in:
Kirk McKusick 2022-07-24 18:01:43 -07:00
parent 1297a704d9
commit bf24d17fda

View File

@ -130,7 +130,13 @@ main(int argc, char *argv[])
usage();
while ((name = *argv++) != NULL) {
if (ufs_disk_fillout(&disk, name) == -1) {
if (ufs_disk_fillout_blank(&disk, name) == -1) {
ufserr(name);
eval |= 1;
continue;
}
disk.d_sblockloc = STDSB_NOHASHFAIL;
if (sbread(&disk) == -1) {
ufserr(name);
eval |= 1;
continue;