Code Monkey home page Code Monkey logo

Comments (7)

cowtowncoder avatar cowtowncoder commented on August 30, 2024

Apologies for the bug & congratulations for being the first UTF-32 user I have ever met! ;-D
(I assume no one has used it before, given that this is the first bug report... and for quite a fundamental bug).

from jackson-core.

cowtowncoder avatar cowtowncoder commented on August 30, 2024

Interestingly the existing UTF-32 tested was NOT catching this issue, because it closed the stream before hitting end-of-file (which would trigger read). I was able to 'fix' this by checking for one more nextToken().
And with that, should be easy enough to fix the issue itself too.

from jackson-core.

cowtowncoder avatar cowtowncoder commented on August 30, 2024

Fixed, now passes modified unit test. Will be in 2.1.2, 2.2.0.

from jackson-core.

cowtowncoder avatar cowtowncoder commented on August 30, 2024

FWIW, patch fix list at: wiki.fasterxml.com/JacksonRelease212

from jackson-core.

jroper avatar jroper commented on August 30, 2024

Well, technically I'm not a UTF-32 user, I was just writing tests that ensured that Play framework lets Jackson detect the encoding, and included UTF-32 for completeness:

https://github.com/jroper/Play20/blob/1a467984ecd15c9f3ede8b245abb70cf4ce20184/framework/test/integrationtest-java/test/test/WsTest.java#L63

We're actually still on Jackson 1.9, but it's easy enough to work around by wrapping the byte array in a ByteArrayInputStream, so we don't need this backported.

from jackson-core.

cowtowncoder avatar cowtowncoder commented on August 30, 2024

Fair enough, I was guessing you were probably just testing UTF-32 handling for sake of completeness. :-)
(and remembered your name from earlier submissions)

If work-around is easy, that's good; but if you do want a fix, 1.9 branch is still open. Actually, come to think of that now, how about I'll see if I can just add the fix myself. It should merge relatively cleanly.

from jackson-core.

cowtowncoder avatar cowtowncoder commented on August 30, 2024

Fixed for 1.9.12 as well now.

from jackson-core.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.