[PATCH] LVMFactory: raise exception when adding LV to full fixed size VG (#1170660)

Vojtech Trefny vtrefny at redhat.com
Tue Dec 16 16:03:53 UTC 2014


---
 blivet/devicefactory.py | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/blivet/devicefactory.py b/blivet/devicefactory.py
index e720fbd..03b7aaf 100644
--- a/blivet/devicefactory.py
+++ b/blivet/devicefactory.py
@@ -1134,6 +1134,9 @@ class LVMFactory(DeviceFactory):
 
             if self.device:
                 self.size += self.device.size
+
+            if self.size == 0:
+                raise DeviceFactoryError("not enough free space for new device")
         else:
             super(LVMFactory, self)._handle_no_size()
 
-- 
2.1.0



More information about the anaconda-patches mailing list