summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorScott Moser <smoser@ubuntu.com>2011-12-21 08:54:03 -0500
committerScott Moser <smoser@ubuntu.com>2011-12-21 08:54:03 -0500
commit64b80e08bc61554e22606edd4153070bcdd18089 (patch)
tree50f6644869c99154f2d57571c1338884443b713f
parentc7e8163c43cb0bb55399c5b47e6eec41a672b8cb (diff)
downloadvyos-cloud-init-64b80e08bc61554e22606edd4153070bcdd18089.tar.gz
vyos-cloud-init-64b80e08bc61554e22606edd4153070bcdd18089.zip
fix bug where first entry in the list presented to mergeTogether was ignored
-rw-r--r--cloudinit/CloudConfig/cc_landscape.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/cloudinit/CloudConfig/cc_landscape.py b/cloudinit/CloudConfig/cc_landscape.py
index 6849b732..e3e4f7ba 100644
--- a/cloudinit/CloudConfig/cc_landscape.py
+++ b/cloudinit/CloudConfig/cc_landscape.py
@@ -56,10 +56,8 @@ def mergeTogether(objs):
merge together ConfigObj objects or things that ConfigObj() will take in
later entries override earlier
"""
- if len(objs) == 0:
- return { }
- cfg = ConfigObj(objs[1])
- for obj in objs[1:]:
+ cfg = ConfigObj({})
+ for obj in objs:
if isinstance(obj, ConfigObj):
cfg.merge(obj)
else: