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

NPE in CrosshairOverlay when the label is empty #194

Closed
ebourg opened this issue Nov 13, 2020 · 2 comments
Closed

NPE in CrosshairOverlay when the label is empty #194

ebourg opened this issue Nov 13, 2020 · 2 comments

Comments

@ebourg
Copy link
Contributor

ebourg commented Nov 13, 2020

There is a NullPointerException in the drawHorizontalCrosshair and drawVerticalCrosshair methods of CrosshairOverlay when the label is an empty string. This happens because TextUtils.calculateRotatedStringBounds() returns a null Shape for empty strings and the calling methods do not test this case.

@jfree
Copy link
Owner

jfree commented Nov 14, 2020

Thanks for the report. I committed a fix.

@jfree jfree closed this as completed Nov 14, 2020
@ebourg
Copy link
Contributor Author

ebourg commented Nov 14, 2020

Thank you!

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