[PATCH] Handle cancelation of device resize in the custom spoke. (#1027947)
David Lehman
dlehman at redhat.com
Fri Nov 22 16:11:41 UTC 2013
---
pyanaconda/ui/gui/spokes/custom.py | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/pyanaconda/ui/gui/spokes/custom.py b/pyanaconda/ui/gui/spokes/custom.py
index f19da80..97fd02a 100644
--- a/pyanaconda/ui/gui/spokes/custom.py
+++ b/pyanaconda/ui/gui/spokes/custom.py
@@ -1464,7 +1464,14 @@ class CustomPartitioningSpoke(NormalSpoke, StorageChecker):
# And then we need to re-check that the max size is actually
# different from the current size.
- if size != device.size:
+ if size != device.size and int(size) == int(device.currentSize):
+ # size has been set back to its original value
+ actions = self.__storage.devicetree.findActions(type="resize",
+ devid=device.id)
+ with ui_storage_logger():
+ for action in actions:
+ self.__storage.devicetree.cancelAction(action)
+ elif size != device.size:
log.debug("scheduling resize of device %s to %s MB", device.name, size)
with ui_storage_logger():
--
1.8.1.4
More information about the anaconda-patches
mailing list