Drop unreachable error message.

LUKS2_reencrypt_status can not return CRYPT_REENCRYPT_INVALID.
This commit is contained in:
Ondrej Kozina
2025-04-25 16:34:05 +02:00
committed by Milan Broz
parent fa84cb8a55
commit c1b5e412c9

View File

@@ -3397,10 +3397,8 @@ static int reencrypt_lock_and_verify(struct crypt_device *cd, struct luks2_hdr *
struct crypt_lock_handle *h;
ri = LUKS2_reencrypt_status(hdr);
if (ri == CRYPT_REENCRYPT_INVALID) {
log_err(cd, _("Failed to get reencryption state."));
if (ri == CRYPT_REENCRYPT_INVALID)
return -EINVAL;
}
if (ri < CRYPT_REENCRYPT_CLEAN) {
log_err(cd, _("Device is not in reencryption."));
return -EINVAL;