Looks ok,
Regards,
Hans
Radek Vykydal wrote:
---
iw/raid_dialog_gui.py | 24 ++++++++++++++----------
1 files changed, 14 insertions(+), 10 deletions(-)
diff --git a/iw/raid_dialog_gui.py b/iw/raid_dialog_gui.py
index 5daab41..578e3e7 100644
--- a/iw/raid_dialog_gui.py
+++ b/iw/raid_dialog_gui.py
@@ -185,17 +185,11 @@ class RaidEditor:
totalDevices=len(raidmembers),
memberDevices=members)
- if self.lukscb and self.lukscb.get_active() and \
- (self.isNew or self.origrequest.format.type != "luks"):
- luksdev = LUKSDevice("luks-%s" % request.name,
- format=format,
- parents=request)
- format = getFormat("luks",
- passphrase=self.storage.encryptionPassphrase)
- request.format = format
- elif self.lukscb and not self.lukscb.get_active() and \
- not self.isNew and self.origrequest.format.type == "luks":
+ # we must destroy luks leaf before original raid request
+ if self.origrequest.format.type == "luks":
+ # => not self.isNew
# destroy luks format and mapped device
+ # XXX remove catching, it should always succeed
try:
luksdev = self.storage.devicetree.getChildren(self.origrequest)[0]
except IndexError:
@@ -205,6 +199,16 @@ class RaidEditor:
actions.append(ActionDestroyDevice(luksdev))
luksdev = None
+ if self.lukscb and self.lukscb.get_active():
+ luksdev = LUKSDevice("luks-%s" % request.name,
+ format=format,
+ parents=request)
+ format = getFormat("luks",
+ passphrase=self.storage.encryptionPassphrase)
+ request.format = format
+ elif self.lukscb and not self.lukscb.get_active() and \
+ self.origrequest.format.type == "luks":
+
# XXXRV not needed as we destroy origrequest ?
actions.append(ActionDestroyFormat(self.origrequest))
_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list