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

FormatUtilities firstIndexOf throws ArrayIndexOutOfBoundsException #64

Closed
alexanderkiel opened this issue Jul 28, 2019 · 2 comments
Closed

Comments

@alexanderkiel
Copy link
Contributor

For example in org.hl7.fhir.r5.formats.FormatUtilities line 143 in method firstIndexOf will show a ArrayIndexOutOfBoundsException if char not found and input less than 1000 bytes long.

Fix: Math.max has to be replaced by Math.min.

I first wanted to create a pull request, but will better not touch the code without proper test execution.

Got the ArrayIndexOutOfBoundsException using validator JAR with a profile hosted by redirect. Problem is that ValidationEngine.loadProfileFromUrl will not follow redirects.

@grahamegrieve
Copy link
Collaborator

fixed

@alexanderkiel
Copy link
Contributor Author

Thanks!

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

2 participants