HomeFreeBSD

Refactor `zhack label repair` and fix `-c` regression on nonzero TXG

Description

Refactor zhack label repair and fix -c regression on nonzero TXG

This commit fixes a likely regression introduced by 64db435 where the
checksum repair functionality (-c or default behavior) will perform
checks and access data associated with the newer undetach (-u)
functionality, resulting in a failure when an uberblock's TXG is not 0
as required by -u but not -c

Additionally, code is refactored for better separation of tasks.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: buzzingwires <buzzingwires@outlook.com>
Closes #17732

Details

Provenance
buzzingwires <buzzingwires@outlook.com>Authored on Sep 12 2025, 10:48 AM
Brian Behlendorf <behlendorf1@llnl.gov>Committed on Sep 17 2025, 3:13 PM
Parents
rGd36684201f1a: man: add silent rules for mancheck
Branches
Unknown
Tags
Unknown