Preserve encryption setting when re-editing new encrypted LVs. (#568547)
The part of the if clause that I'm removing will never be true anyhow
-- it requires a preexisting format, but it is inside a clause that
only gets entered for non-existing LVs, which obviously cannot contain
pre-existing formats.
---
iw/lvm_dialog_gui.py | 13 ++++++++-----
1 files changed, 8 insertions(+), 5 deletions(-)
diff --git a/iw/lvm_dialog_gui.py b/iw/lvm_dialog_gui.py
index bae72f5..9cc87b5 100644
--- a/iw/lvm_dialog_gui.py
+++ b/iw/lvm_dialog_gui.py
@@ -722,12 +722,15 @@ class VolumeGroupEditor:
continue
format = fmt_class(mountpoint=mountpoint)
- if self.lukscb and self.lukscb.get_active() and
- (templv.format.type != "luks" or
- (templv.format.exists and not templv.format.hasKey)):
- newluks = format
- format = getFormat("luks",
+ if self.lukscb and self.lukscb.get_active():
+ if templv.format.type != "luks":
+ newluks = format
+ format = getFormat("luks",
passphrase=self.storage.encryptionPassphrase)
+ else:
+ newluks = format
+ format = templv.format
+
templv.format = format
else:
# existing lv
--
1.6.6
_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list