[master 3/5] Unset obsolete format before updating device size.

dwlehman installerbot-noreply at redhat.com
Fri Jul 24 21:41:11 UTC 2015


From: David Lehman <dlehman at redhat.com>

The format type can impose limits on the size of the device, so
clear it before setting the size.
---
 blivet/devicefactory.py | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/blivet/devicefactory.py b/blivet/devicefactory.py
index 634eab2..285d4b5 100644
--- a/blivet/devicefactory.py
+++ b/blivet/devicefactory.py
@@ -676,6 +676,10 @@ def _set_raid_level(self):
         pass
 
     def _set_size(self):
+        # reset the device's format before allocating partitions, &c
+        if self.device.format.type != self.fstype:
+            self.device.format = None
+
         # this is setting the device size based on the factory size and the
         # current size of the container
         self._set_device_size()


-- 
To view this commit on github, visit https://github.com/rhinstaller/blivet/commit/a5000d45bbe152e9b302169582f114642db80019


More information about the anaconda-patches mailing list