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

[PATCH] Don't pass the default clearPartType value to the device tree.



In non-kickstart installs, clearPartType gets set to CLEARPART_TYPE_LINUX
before the user makes a choice. We shouldn't pass that value to the
device tree constructor unless we're doing a kickstart install.
---
 storage/__init__.py |   10 +++++++++-
 1 files changed, 9 insertions(+), 1 deletions(-)

diff --git a/storage/__init__.py b/storage/__init__.py
index 033eeb6..d37fa40 100644
--- a/storage/__init__.py
+++ b/storage/__init__.py
@@ -281,10 +281,18 @@ class Storage(object):
                                           _("Finding storage devices..."))
         self.iscsi.startup(self.anaconda.intf)
         self.zfcp.startup()
+        if not self.anaconda.isKickstart:
+            # clearPartType defaults to CLEARPART_TYPE_LINUX, but the user
+            # has not made any selection, so we need to ignore it during
+            # population of the device tree
+            clearPartType = CLEARPART_TYPE_NONE
+        else:
+            clearPartType = self.clearPartType
+
         self.devicetree = DeviceTree(intf=self.anaconda.intf,
                                      ignored=self.ignoredDisks,
                                      exclusive=self.exclusiveDisks,
-                                     type=self.clearPartType,
+                                     type=clearPartType,
                                      clear=self.clearPartDisks,
                                      reinitializeDisks=self.reinitializeDisks,
                                      protected=self.protectedPartitions,
-- 
1.6.0.6


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