[PATCH] Don't write duplicate lines for encrypted block devices.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The underlying encrypted block device's writeKS method gets called
from within the dm-crypt/luks device's writeKS method, so skip the
underlying devices in the main loop in Storage.writeKS.

Resolves: rhbz#605938
---
 pyanaconda/storage/__init__.py |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/pyanaconda/storage/__init__.py b/pyanaconda/storage/__init__.py
index 2ae5ae9..8edd1fd 100644
--- a/pyanaconda/storage/__init__.py
+++ b/pyanaconda/storage/__init__.py
@@ -1275,7 +1275,7 @@ class Storage(object):
             else:
                 dict[action.device.path] = [action]
 
-        for device in self.devices:
+        for device in [d for d in self.devices if d.format.type != "luks"]:
             # If there's no action for the given device, it must be one
             # we are reusing.
             if not dict.has_key(device.path):
@@ -1291,6 +1291,7 @@ class Storage(object):
         self.iscsi.writeKS(f)
         self.fcoe.writeKS(f)
         self.zfcp.writeKS(f)
+        f.write("\n")
 
     def turnOnSwap(self, upgrading=None):
         self.fsset.turnOnSwap(intf=self.intf,
-- 
1.7.3.4

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list


[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux