commit | 7b77188e89182e0cf00d42f5556f972a739d6beb | [log] [tgz] |
---|---|---|
author | Martin v. Löwis <martin@v.loewis.de> | Sun Feb 19 20:55:05 2012 +0100 |
committer | Martin v. Löwis <martin@v.loewis.de> | Sun Feb 19 20:55:05 2012 +0100 |
tree | 7a1afd31b81475eab8531907c76cc460e5516611 | |
parent | 14aa280de23ecb6c31ffbde4a12c1a0a6f5493e0 [diff] [blame] |
Create _attr/_attrNS lazily.
diff --git a/Lib/xml/dom/expatbuilder.py b/Lib/xml/dom/expatbuilder.py index b4b28e4..ff9c1f1 100644 --- a/Lib/xml/dom/expatbuilder.py +++ b/Lib/xml/dom/expatbuilder.py
@@ -760,6 +760,7 @@ del self._ns_ordered_prefixes[:] if attributes: + node._ensure_attributes() _attrs = node._attrs _attrsNS = node._attrsNS for i in range(0, len(attributes), 2):