Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

XML codec failed due to special charecter like '\u0000' #4

Open
tutufool opened this issue Jan 18, 2013 · 0 comments
Open

XML codec failed due to special charecter like '\u0000' #4

tutufool opened this issue Jan 18, 2013 · 0 comments

Comments

@tutufool
Copy link

Hi,

I got some exception when trying to using xml codec:

Caused by: com.ctc.wstx.exc.WstxIOException: Invalid null character in text to output
at com.ctc.wstx.sw.BaseStreamWriter.writeCharacters(BaseStreamWriter.java:488)
at protobuf.codec.xml.XmlWriter.writeFieldValue(XmlWriter.java:68)
at protobuf.codec.xml.XmlWriter.writeXml(XmlWriter.java:47)
at protobuf.codec.xml.XmlCodec.writeToStream(XmlCodec.java:69)
... 26 more
Caused by: java.io.IOException: Invalid null character in text to output
at com.ctc.wstx.api.InvalidCharHandler$FailingHandler.convertInvalidChar(InvalidCharHandler.java:51)
at com.ctc.wstx.sw.XmlWriter.handleInvalidChar(XmlWriter.java:623)
at com.ctc.wstx.sw.BufferingXmlWriter.writeCharacters(BufferingXmlWriter.java:475)
at com.ctc.wstx.sw.BaseStreamWriter.writeCharacters(BaseStreamWriter.java:486)
... 29 more

It seems null characters like '\u0000' - '\u0020' can't be rendered correctly.

I'm not sure if it's a bug for woodstox (or it's already fixed in newer version).

Could you please take a look?

Thanks
Ma Ling

tutufool pushed a commit to tutufool/protobuf-codec that referenced this issue Jan 22, 2013
sijuv#5
XML codec throw java.util.NoSuchElementException when message is too long

sijuv#4
XML codec failed due to special charecter like '\u0000'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant