Mercurial > genshi > genshi-test
comparison markup/output.py @ 178:8fb7df2e1281
Fix bug in XHTML serialization: all elements were allowed to be written out as empty if the namespace was set.
author | cmlenz |
---|---|
date | Mon, 21 Aug 2006 15:36:29 +0000 |
parents | dbae9efe5704 |
children | 50eab0469148 |
comparison
equal
deleted
inserted
replaced
177:dbae9efe5704 | 178:8fb7df2e1281 |
---|---|
229 buf += [' ', attrname, '="', attrname, '"'] | 229 buf += [' ', attrname, '="', attrname, '"'] |
230 else: | 230 else: |
231 buf += [' ', attrname, '="', escape(value), '"'] | 231 buf += [' ', attrname, '="', escape(value), '"'] |
232 ns_attrib = [] | 232 ns_attrib = [] |
233 | 233 |
234 if (tagns and tagns != namespace) or tagname in empty_elems: | 234 if (tagns and tagns != namespace.uri) or tagname in empty_elems: |
235 kind, data, pos = stream.next() | 235 kind, data, pos = stream.next() |
236 if kind is END: | 236 if kind is END: |
237 buf += [' />'] | 237 buf += [' />'] |
238 else: | 238 else: |
239 buf += ['>'] | 239 buf += ['>'] |