[rhel7/master] Check boot args for None (#1075918)

Brian C. Lane bcl at redhat.com
Mon Mar 24 16:50:43 UTC 2014


When there are multiple boot args, some may be empty, like inst.dd, so
check the new value and the previous value to make sure they are not
None.

Related: rhbz#1073130
Resolves: rhbz#1075918
---
 pyanaconda/flags.py | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/pyanaconda/flags.py b/pyanaconda/flags.py
index 1435311..cbba624 100644
--- a/pyanaconda/flags.py
+++ b/pyanaconda/flags.py
@@ -167,8 +167,9 @@ class BootArgs(OrderedDict):
                 val = None
 
             # Duplicate args create a space separated string
-            if key in self:
-                self[key] = self[key] + " " + val
+            if self.get(key, None):
+                if val:
+                    self[key] = self[key] + " " + val
             else:
                 self[key] = val
 
-- 
1.8.5.3



More information about the anaconda-patches mailing list