close luks mapper and end with an error on lock format failures

This commit is contained in:
Jaromil 2020-12-29 10:56:20 +01:00
parent d8360688b3
commit 0ac5a34c20

3
tomb
View File

@ -2043,7 +2043,8 @@ lock_tomb_with_key() {
[[ $? == 0 ]] || {
_warning "Tomb format returned an error."
_warning "Your tomb ::1 tomb file:: may be corrupted." $TOMBFILE }
_sudo cryptsetup luksClose tomb.tmp
_failure "Your tomb ::1 tomb file:: may be corrupted." $TOMBFILE }
# Sync
_sudo cryptsetup luksClose tomb.tmp