WaterSweet / mochiweb

Automatically exported from code.google.com/p/mochiweb
Other
0 stars 0 forks source link

Mochiweb_html function clauses trying to encode parsed <?xml tags #67

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. X = <<"<html><?xml:namespace prefix=\"o\"
ns=\"urn:schemas-microsoft-com:office:office\"?></html>">.
2. Y = mochiweb_html:parse(X).
3. Z = mochiweb_html:to_html(Y).

What is the expected output? What do you see instead?
I expect to see the <?xml tag correctly encoded, instead I get this error:

exception error: no function clause matching
mochiweb_html:attrs_to_html(<<"xml:namespace">>,[])

What version of the product are you using? On what operating system?

Latest SVN.

Please provide any additional information below.

Patch with tests is attached.

Original issue reported on code.google.com by tetrachl...@gmail.com on 20 Mar 2010 at 6:03

Attachments:

GoogleCodeExporter commented 8 years ago
Thanks for the patch, looks good. Applied in r144

Original comment by bob.ippo...@gmail.com on 22 Mar 2010 at 11:04