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

The parser throws StringIndexOutOfBoundsException/ArrayIndexOutOfBoundsException for some inputs #22

Closed
wrandelshofer opened this issue Aug 12, 2022 · 6 comments

Comments

@wrandelshofer
Copy link
Owner

The parser throws StringIndexOutOfBoundsException/ArrayIndexOutOfBoundsException for some inputs.
For example with the following input: "0x".

This issue has been discovered in FasterXML/jackson-core#809

The only exceptions, that the parser may throw are:

  • NumberFormatException when the input is illegal
  • OutOfMemoryException when the JVM fails to allocate memory for objects created by the parser
@wrandelshofer
Copy link
Owner Author

Fixed in the following branches and revisions:

@blacelle
Copy link

@wrandelshofer Do you plan a release with this fix (including a m2 central deploy?) Thanks

@wrandelshofer
Copy link
Owner Author

I haven't released a fix just for this issue, because I thought there was little interest in parsing hexadecimal floating point literals.

I am planning to make release and m2 central deploy after fixing issue #19.

@pjfanning
Copy link
Contributor

@wrandelshofer thanks for all your hard work

We use your java8 code in jackson-core. If you publish a jar with your java8 branch code that would be great - we would change our build to use your published jars and that shades the class packages to include them in jackson-core jar.

One solution would be to append '-java8' to the artifact name (and '-java17' for the java17 jar). Or maven supports 'classifiers' which basically lead to a similar result.

@wrandelshofer
Copy link
Owner Author

@blacelle
I have now released and deployed version 0.5.0 of fastdoubleparser. This release contains the fix for this issue (and other improvements).
https://search.maven.org/artifact/ch.randelshofer/fastdoubleparser/0.5.0/jar

@blacelle
Copy link

Excellent. And it has been pushed to m2central (while 0.4.0 has not been pushed). Thx a lot!

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

3 participants