[f20-branch/rhel7-branch][PATCH] Do not allow setting empty LV names (#1017504)
Vratislav Podzimek
vpodzime at redhat.com
Thu Oct 17 13:12:19 UTC 2013
If user tries to set empty LV name, the easiest thing we can do to prevent
issues is to reset it to the old value.
Signed-off-by: Vratislav Podzimek <vpodzime at redhat.com>
---
pyanaconda/ui/gui/spokes/custom.py | 3 +++
1 file changed, 3 insertions(+)
diff --git a/pyanaconda/ui/gui/spokes/custom.py b/pyanaconda/ui/gui/spokes/custom.py
index cc757b5..2f36b33 100644
--- a/pyanaconda/ui/gui/spokes/custom.py
+++ b/pyanaconda/ui/gui/spokes/custom.py
@@ -1127,6 +1127,9 @@ class CustomPartitioningSpoke(NormalSpoke, StorageChecker):
changed_name = False
if self._nameEntry.get_sensitive():
name = self._nameEntry.get_text()
+ if name == "":
+ name = old_name
+ self._nameEntry.set_text(name)
changed_name = (name != old_name)
else:
# name entry insensitive means we don't control the name
--
1.7.11.7
More information about the anaconda-patches
mailing list