libxml2 serializes documents without an encoding declaration differently than
documents with an explicit UTF-8 encoding:
$ echo '<?xml version="1.0"?><doc>Käse</doc>' |xmllint -
<?xml version="1.0"?>
<doc>Käse</doc>
$ echo '<?xml version="1.0" encoding="utf-8"?><doc>Käse</doc>' |xmllint -
<?xml version="1.0" encoding="utf-8"?>
<doc>Käse</doc>
Since the encoding should default to UTF-8, can anyone explain why this
decision was made?
Nick
_______________________________________________
xml mailing list, project page http://xmlsoft.org/
xml@gnome.org
https://mail.gnome.org/mailman/listinfo/xml