Send in an empty list instead of None.
authorJohan Dahlin <jdahlin@litl.com>
Fri, 20 Feb 2009 12:50:01 +0000 (09:50 -0300)
committerJohan Dahlin <johan@gnome.org>
Fri, 20 Feb 2009 12:50:01 +0000 (09:50 -0300)
giscanner/xmlwriter.py

index 3c14162..9f222e9 100644 (file)
@@ -120,6 +120,8 @@ class XMLWriter(object):
         self.write_line(prefix + attrs + suffix)
 
     def push_tag(self, tag_name, attributes=None):
+        if attributes is None:
+            attributes = []
         self._open_tag(tag_name, attributes)
         self._tag_stack.append(tag_name)
         self._indent += self._indent_unit