You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@olingo.apache.org by "Michele Preti (JIRA)" <ji...@apache.org> on 2017/11/29 14:17:00 UTC

[jira] [Created] (OLINGO-1209) Bugged dependency

Michele Preti created OLINGO-1209:
-------------------------------------

             Summary: Bugged dependency
                 Key: OLINGO-1209
                 URL: https://issues.apache.org/jira/browse/OLINGO-1209
             Project: Olingo
          Issue Type: Bug
          Components: odata4-server
    Affects Versions: (Java) V4 4.4.0
            Reporter: Michele Preti


should update aalto-xml to version 1.0.0, because 0.9.10 has a bug that cause a wrong character encoding in multi-byte characters, try for yourself:


{code:java}
                OutputStream out = new BufferedOutputStream(new FileOutputStream(new File(<filepath>)));
		Utf8XmlWriter w = new Utf8XmlWriter(new WriterConfig(), out);
		w.writeStartTagStart(w.constructName("test"));
		w.writeStartTagEnd();
		String text = String.join("", Collections.nCopies(1000000, "°"));
		w.writeCharacters(text );
		w.writeEndTag(w.constructName("test"));
		w.flush();
		w.close(true);
{code}

this will write an xml file containing "<test>°°°...°°°</test>"
the encoding will not be correct, at some point it will contains these bypes "C2 B0 B0" instead of "C2 B0" (in hex). This is not a valid encoding




--
This message was sent by Atlassian JIRA
(v6.4.14#64029)