[blivet:master 09/11] Add another check for resizable in FS.doResize()
mulhern
amulhern at redhat.com
Tue Nov 25 23:22:45 UTC 2014
It can change in the middle of the method.
Signed-off-by: mulhern <amulhern at redhat.com>
---
blivet/formats/fs.py | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/blivet/formats/fs.py b/blivet/formats/fs.py
index eefabbc..175d95e 100644
--- a/blivet/formats/fs.py
+++ b/blivet/formats/fs.py
@@ -465,6 +465,11 @@ class FS(DeviceFormat):
# so run the check one last time and bump up the size if it was too
# small.
self.updateSizeInfo()
+
+ # Check again if resizable is True, as updateSizeInfo() can change that
+ if not self.resizable:
+ raise FSResizeError("filesystem not resizable", self.device)
+
if self.targetSize < self.minSize:
self.targetSize = self.minSize
log.info("Minimum size changed, setting targetSize on %s to %s",
--
1.9.3
More information about the anaconda-patches
mailing list